*** how to set up a variable in Linux? *** - Programmers Heaven

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

*** how to set up a variable in Linux? ***

I am a newbie. I know this is a little off-stream of programming, but it is the problem when I tried to program in linux. I wonder if there is a way to set up a variable, say $VAR = /home/root, so that I can use
cd $VAR
instead of
cd /home/root

Comments

  • IDKIDK Posts: 1,784Member
    : I am a newbie. I know this is a little off-stream of programming,
    : but it is the problem when I tried to program in linux. I wonder if
    : there is a way to set up a variable, say $VAR = /home/root, so that
    : I can use
    : cd $VAR
    : instead of
    : cd /home/root
    :

    See man export
Sign In or Register to comment.