Changing Default Editor in profile

2006-09-08 Thread Huy Ton That

under my home directory for root under .profile I added the line:

EDITOR=pico;export EDITOR

where no such line existed for EDITOR before; this line exists in my
personal account that I use and my default for external launched editors is
now pico such that I can edit crontab stuff easily.  However, when I ssh in
and then su, I try to run crontab only to find it is still booting into 'vi'
by default.  Any ideas how I can get this loaded?
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Changing Default Editor in profile

2006-09-08 Thread backyard


--- Huy Ton That [EMAIL PROTECTED] wrote:

 under my home directory for root under .profile I
 added the line:
 
 EDITOR=pico;export EDITOR
 
 where no such line existed for EDITOR before; this
 line exists in my
 personal account that I use and my default for
 external launched editors is
 now pico such that I can edit crontab stuff easily. 
 However, when I ssh in
 and then su, I try to run crontab only to find it is
 still booting into 'vi'
 by default.  Any ideas how I can get this loaded?
 ___
 freebsd-questions@freebsd.org mailing list

http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to
 [EMAIL PROTECTED]
 

yeah, I'm not sure what the switch is for su I think
its -w check man, but you have to load your profile
for root which is a switch to su. by default it uses
the profile of the user running su. the switch loads
the profile for the user your su'ing to.

-brian

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Changing Default Editor in profile

2006-09-08 Thread Dominique Goncalves

Hi,

On 9/8/06, Huy Ton That [EMAIL PROTECTED] wrote:

under my home directory for root under .profile I added the line:

EDITOR=pico;export EDITOR

where no such line existed for EDITOR before; this line exists in my
personal account that I use and my default for external launched editors is
now pico such that I can edit crontab stuff easily.  However, when I ssh in
and then su, I try to run crontab only to find it is still booting into 'vi'
by default.  Any ideas how I can get this loaded?


You have to use su -, if you want load your root's environnement.
su(1) for more explications.

HTH

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]



Regards.

--
There's this old saying: Give a man a fish, feed him for a day. Teach
a man to fish, feed him for life.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Changing Default Editor in profile

2006-09-08 Thread Huy Ton That

Thank you sirs!!!  That did the trick!


On 9/8/06, Dominique Goncalves [EMAIL PROTECTED] wrote:


Hi,

On 9/8/06, Huy Ton That [EMAIL PROTECTED] wrote:
 under my home directory for root under .profile I added the line:

 EDITOR=pico;export EDITOR

 where no such line existed for EDITOR before; this line exists in my
 personal account that I use and my default for external launched editors
is
 now pico such that I can edit crontab stuff easily.  However, when I ssh
in
 and then su, I try to run crontab only to find it is still booting into
'vi'
 by default.  Any ideas how I can get this loaded?

You have to use su -, if you want load your root's environnement.
su(1) for more explications.

HTH
 ___
 freebsd-questions@freebsd.org mailing list
 http://lists.freebsd.org/mailman/listinfo/freebsd-questions
 To unsubscribe, send any mail to 
[EMAIL PROTECTED]


Regards.

--
There's this old saying: Give a man a fish, feed him for a day. Teach
a man to fish, feed him for life.


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Changing Default Editor in profile

2006-09-08 Thread Gerard Seibert
Huy Ton That wrote:

 under my home directory for root under .profile I added the line:
 
 EDITOR=pico;export EDITOR
 
 where no such line existed for EDITOR before; this line exists in my
 personal account that I use and my default for external launched editors is
 now pico such that I can edit crontab stuff easily.  However, when I ssh in
 and then su, I try to run crontab only to find it is still booting into 'vi'
 by default.  Any ideas how I can get this loaded?

Try using: su -m instead.


-- 
Gerard Seibert
[EMAIL PROTECTED]


Give a man a fire, he is warm for a night. Set a man on fire and he is
warm for the rest of his life.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]


~/.profile and tcsh (was: Changing Default Editor in profile)

2006-09-08 Thread Karol Kwiatkowski
  under my home directory for root under .profile I added the line:
 
  EDITOR=pico;export EDITOR

 You have to use su -, if you want load your root's environnement.
 su(1) for more explications.

 Thank you sirs!!!  That did the trick!

Hmmm, interesting. I was under the impression that ~/.profile file is
used by sh and not by tcsh. Indeed, I can't find it being mentioned in
tcsh(1) manpage. Am I missing something? Pointers to TFM welcomed, of
course :)

Karol

-- 
Karol Kwiatkowski  freebsd at orchid dot homeunix dot org
OpenPGP: http://www.orchid.homeunix.org/carlos/gpg/0x06E09309.asc



signature.asc
Description: OpenPGP digital signature


Re: Changing Default Editor in profile

2006-09-08 Thread Jerold McAllister
Dominique Goncalves writes: 

Hi, 


On 9/8/06, Huy Ton That [EMAIL PROTECTED] wrote:
under my home directory for root under .profile I added the line: 

EDITOR=pico;export EDITOR 


where no such line existed for EDITOR before; this line exists in my
personal account that I use and my default for external launched editors 
is
now pico such that I can edit crontab stuff easily.  However, when I ssh 
in
and then su, I try to run crontab only to find it is still booting into 
'vi'

by default.  Any ideas how I can get this loaded?


You have to use su -, if you want load your root's environnement.
su(1) for more explications. 



That is the specific answer to your question, but here is an additional
caution. 


You do not want to have the main root account set up with anything
but the minimal stuff that will be available in single user mode with
only the / partition mounted just in case you have trouble and need it.
For it to be root it needs to have UID = 0 and best to have GID = 0.
It doesn't need to be named root. 


So, I would suggest making your own separate root account - maybe named
something like domr or domR or something else convenient and then give
that account all the nice things like your favorite shell and editor, etc
so you can use that as root when all the system is up and happy and leave
the main root with /bin/sh as shell and /usr/bin/vi as editor, etc.
I usually even put a copy of vi in /bin just for those occasions. 

Just a suggestion, 

jerry 


HTH

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
[EMAIL PROTECTED] 



Regards. 


--
There's this old saying: Give a man a fish, feed him for a day. Teach
a man to fish, feed him for life.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
[EMAIL PROTECTED] 





___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to [EMAIL PROTECTED]