Leser: 28
1
2
3
4
5
6
$ echo $EDITOR
/usr/bin/vim
$ perl -e 'print $ENV{EDITOR} . "\n"'
$ export EDITOR=/usr/bin/vim && perl -e 'print $ENV{EDITOR} . "\n"'
/usr/bin/vim
$ENV{EDITOR}
1
2
3
4
5
6
7
8
9
10
11
12
sidburn@sid:~$ echo $FOO
sidburn@sid:~$ FOO="bar"
sidburn@sid:~$ echo $FOO
bar
sidburn@sid:~$ perl -wle 'print $ENV{FOO}'
Use of uninitialized value $ENV{"FOO"} in print at -e line 1.
sidburn@sid:~$
sidburn@sid:~$ export FOO
sidburn@sid:~$ perl -wle 'print $ENV{FOO}'
bar