help-gnu-emacs
[Top][All Lists]
Advanced

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

Re: How to make emacs stop trying to load /home/sb/.emacs after su to ro


From: Tomas Nordin
Subject: Re: How to make emacs stop trying to load /home/sb/.emacs after su to root?
Date: Tue, 09 Jul 2019 22:04:20 +0200

address@hidden writes:

> On Tue, Jul 09, 2019 at 09:00:11PM +0200, Tomas Nordin wrote:
>> Perry Smith <address@hidden> writes:
>
> [...]
>
>> >> How can I make emacs stop loading the original user's .emacs when
>> >> logged in as root?
>> >
>> > Can you do “id” after you do the su?  Usually “su - root” is the suggested 
>> > method.
>> > The ‘-‘ causes the users environment to get loaded or something.  Never 
>> > looked
>> > too deep into it.
>> 
>> After su;
>> 
>> # id
>> uid=0(root) gid=0(root) groups=0(root)
>> 
>> After su - root;
>> 
>> # id
>> uid=0(root) gid=0(root) groups=0(root)
>> 
>> but after this latter way of getting root emacs did not try to load
>> /home/tomas/.emacs
>> 
>> Just metooing
>
> Have you checked the environment? What does $HOME say? (although the
> "su -" part lets one expect that the HOME var is set anew: checking
> won't hurt :-)

echo $HOME gave /root after both su methods

>
> Cheers
> -- t



reply via email to

[Prev in Thread] Current Thread [Next in Thread]