Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
failure in /etc/profile ???
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
rbrosi
n00b
n00b


Joined: 04 Mar 2003
Posts: 16

PostPosted: Fri Mar 07, 2003 10:21 am    Post subject: failure in /etc/profile ??? Reply with quote

Hi,

if i am root, path will not set me the answers from /etc/profile.env

is this wanted that way ???



Code:

# /etc/profile:
# $Header: /home/cvsroot/gentoo-src/rc-scripts/etc/profile,v 1.15 2002/11/18 19:
39:22 azarah Exp $

if [ -e "/etc/profile.env" ]
then
        source /etc/profile.env
fi

#077 would be more secure, but 022 is generally quite realistic
umask 022

if [ `/usr/bin/whoami` = 'root' ]
then
        if [ "$SHELL" = '/bin/bash' ] || [ "$SHELL" = '/bin/sh' ]
        then
                export PS1='\[\033[01;31m\]\h \[\033[01;34m\]\W \$ \[\033[00m\]'
        fi
        export PATH="/bin:/sbin:/usr/bin:/usr/sbin:${ROOTPATH}"
else
        if [ "$SHELL" = '/bin/bash' ] || [ "$SHELL" = '/bin/sh' ]
        then
                export PS1='\[\033[01;32m\]\u@\h \[\033[01;34m\]\W \$ \[\033[00m
\]'
        fi
        export PATH="/bin:/usr/bin:${PATH}"
fi
unset ROOTPATH

if [ -z "$INPUTRC" -a ! -f "$HOME/.inputrc" ]; then
        export INPUTRC="/etc/inputrc"
fi


I installed X11R6, and added the variables to /etc/env.d/
when i do source /etc/profile all variables except path will be set correct.
So X11R6 pathes are not in env and i can't really use it.

WHY


Best Regards,

Rainer
Back to top
View user's profile Send private message
sheepdog
Guru
Guru


Joined: 14 Oct 2002
Posts: 369
Location: Edison Enterprises Inc., Lake Oswego, Oregon, USA

PostPosted: Fri Mar 07, 2003 4:28 pm    Post subject: convention Reply with quote

I think it's just conventional for root to work from the command line and therefore have little need for the path to X. Your welcome to change this for your system as you please.
Back to top
View user's profile Send private message
pjp
Administrator
Administrator


Joined: 16 Apr 2002
Posts: 20067

PostPosted: Fri Mar 07, 2003 5:55 pm    Post subject: Reply with quote

Moved from Installing Gentoo.
_________________
Quis separabit? Quo animo?
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum