On Saturday 05 September 2009 19:17:46 Denys Vlasenko wrote: > On Thursday 13 August 2009 10:17, Mike Frysinger wrote: > > side > > note -- setting PWD is the same thing as doing `cd`. so `PWD=/` and `cd > > /` are equivalent. > > I discovered that it is not true (in bash). > > Setting PWD does not do that. bash lies to you by showing wrong prompt: > > shadow:~# PWD=/ > shadow:/# PWD=/tmp > shadow:/tmp# /bin/pwd > /root > shadow:/# set | grep PS1 > PS1='\h:\w\$ ' > > Apparently, \w simply is substituted by $PWD, even if the value is wrong.
ah i was tricked by my prompt. thanks for digging further than face value ;). -mike
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
