[OT] Does "~" always point to $HOME?

youshi10 at u.washington.edu youshi10 at u.washington.edu
Thu Jan 25 21:30:57 UTC 2007


On Thu, 25 Jan 2007, Bill Campbell wrote:

> On Thu, Jan 25, 2007, youshi10 at u.washington.edu wrote:
>> Hello again,
>>    I'm revising some documentation that has examples of running Unix
>>    commands and I want to make sure that my steps are correct, such that I
>>    can substitute the tilde character ('~') for $HOME. The only issue I
>>    can see with this is an improper configuration with sudo (ran into some
>>    problems with $HOME in the past using sudo on Gentoo), but I'm pretty
>>    sure that sudo's setup on the machine cluster properly.
>
> That's true on most relatively modern shells, but not on pure
> Bourne Shell, /bin/sh.
>
> As for ``sudo'', ``sudo -'' invokes the login environment while a
> plain ``sudo'' doesn't.
>
> Bill
> --
> INTERNET:   bill at Celestial.COM  Bill Campbell; Celestial Software LLC
> URL: http://www.celestial.com/  PO Box 820; 6641 E. Mercer Way
> FAX:            (206) 232-9186  Mercer Island, WA 98040-0820; (206) 236-1676
>
> ``If we got one-tenth of what was promised to us in these acceptance
> speeches there wouldn't be any inducement to go to heaven.''
>    Will Rogers

Ok, I'll stick with home then.
Thanks!
-Garrett




More information about the freebsd-questions mailing list