tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

/bin/sh tilde expansion



Hi,

When exactly does /bin/sh's tilde expansion take place?

$ /bin/sh -x
$ export DIR=~/tmp
+ export DIR=~/tmp
$ ls -ld $DIR
+ ls -ld ~/tmp
ls: ~/tmp: No such file or directory
$ cd
+ cd
$ ls -ld tmp
+ ls -ld tmp
drwx------  2 jschauma  users  512 Jul  4 21:37 tmp
$ ^D
$ bash -x
$ export DIR=~/tmp  
+ export DIR=/home/jschauma/tmp
+ DIR=/home/jschauma/tmp
$ ls -ld $DIR
+ ls -ld /home/jschauma/tmp
drwx------  2 jschauma  users  512 Jul  4 21:37 /home/jschauma/tmp
$ 

??

-Jan

Attachment: pgpDost_H13aE.pgp
Description: PGP signature



Home | Main Index | Thread Index | Old Index