Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[bashrc] pas lu pour le root (resolu)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index French
View previous topic :: View next topic  
Author Message
alctraz
Tux's lil' helper
Tux's lil' helper


Joined: 12 May 2004
Posts: 117
Location: belgium

PostPosted: Thu Jan 20, 2005 11:12 pm    Post subject: [bashrc] pas lu pour le root (resolu) Reply with quote

Slt, j'ai un pti pb de lecture de mon .bashrc pour le root...

Comme je veux le mm bashrc pour le user et le root, j'ai cree des fichiers ~/.bashrc et /root/.bashrc contenant:
Code:
source /etc/skel/.bashrc

et j'edite /etc/skel/.bashrc pour y apporter les modifications que je souhaite pour tous les utilisateurs.

D'autre part, pour 'debuger' j'ai ajoute la ligne suivante dans le /etc/skel/.bashrc:
Code:
echo "/etc/skel/.bashrc..." # debug


Maintenant, voila ce qui apparait qd je lance Xterm:
Code:
/etc/skel/.bashrc...
alctraz@localhost ~ $ echo $USER
alctraz
alctraz@localhost ~ $ su 
Password:
/etc/skel/.bashrc...
localhost alctraz # echo $USER
alctraz
localhost alctraz # su -
localhost ~ # echo $USER
root


J'aimerais pouvoir utiliser 'su -' pour me logger en root, pour avoir le variables d'environement comme $USER mises a jour, cependant 'su -' ne veut pas lire le .bashrc alors que, comme on peut le constater, 'su' tout court le fait...
Le man de su est pas tres explicite... est-ce que c'est le comportement normal?
Comment faire pour que les variables d'environement soient mises a jour ET que les bashrc soit lu?

merci


Last edited by alctraz on Fri Jan 21, 2005 4:53 pm; edited 1 time in total
Back to top
View user's profile Send private message
yuk159
Veteran
Veteran


Joined: 18 Apr 2003
Posts: 1802
Location: noumea ,nouvelle-caledonie

PostPosted: Thu Jan 20, 2005 11:33 pm    Post subject: Reply with quote

As tu crée le lien ou le fichier ~/.bash_profile ?
qui se trouve lui aussi dans /etc/skel
_________________
The box said: "Requires Windows 98/2000/XP/NT, or better."
So, I installed LINUX!
Instagram
Back to top
View user's profile Send private message
alctraz
Tux's lil' helper
Tux's lil' helper


Joined: 12 May 2004
Posts: 117
Location: belgium

PostPosted: Thu Jan 20, 2005 11:53 pm    Post subject: Reply with quote

yuk159 wrote:
As tu crée le lien ou le fichier ~/.bash_profile ?
qui se trouve lui aussi dans /etc/skel


non je l'avais pas fait, et c'etait ca le probleme, ca fonctionne maintenant

merci
Back to top
View user's profile Send private message
kernelsensei
Bodhisattva
Bodhisattva


Joined: 22 Feb 2004
Posts: 5619
Location: Woustviller/Moselle/FRANCE (49.07°N;7.02°E)

PostPosted: Fri Jan 21, 2005 2:08 pm    Post subject: Reply with quote

un petit (resolu) dans le titre stp !

Merci !
_________________
$ ruby -e'puts " .:@BFegiklnorst".unpack("x4ax7aaX6ax5aX15ax4aax6aaX7ax2aX5aX8 \
axaX3ax8aX4ax6aX3aX6ax3ax3aX9ax4ax2aX9axaX6ax3aX2ax4ax3aX4aXaX12ax10aaX7a").join'
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index French 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