You are not logged in.
Pages: 1
ciao, non riesco ad ottenere la shell colorata come root se accedo con un su (busybox).
Esempio: loggato come utente tux
xterm
tux@slitaz:~$ << giusta # Green and blue for users
su
Password:
root@slitaz:/home/tux$ >> sbagliata ancora # Green and blue for users
exit
login root
Password:
root@slitaz:~$ >> giusta # Red and blue for root
sono presenti /etc/bashrc and /etc/profile
per puro caso riuscii durante le prove a far funzionare la shell correttamente, ma ora non riesco più a risalire a quali impostazioni sono necessarie per ottenerla.
Chi mi sa dire come si ottiene?
----------------------------------------------------------------------------------------------------------------------
Xterm Colored prompt issue
hello, i can't get the colored shell as root if i login with a su (busybox).
Example: logged in as user tux
xterm
tux@slitaz:~$ << right # Green and blue for users
su
Password:
root@slitaz:/home/tux$ >> wrong again # Green and blue for users
exit
login root
Password:
root@slitaz:~$ >> right # Red and blue for root
there are /etc/bashrc and /etc/profile
by pure chance I managed to get the shell to work correctly, but now I can't find out what settings are needed to get it.
Who can tell me how to get it?
Offline
this solution is an horrible workaround, but work!
add at end of file ~.profile this alias
alias su='export PS1="\[\e[1;31m\]\u@\h\[\e[0m\]:\[\e[1;34m\]\w\[\e[0m\]\$ " && su && export PS1="\[\e[1;32m\]\u@\h\[\e[0m\]:\[\e[1;34m\]\w\[\e[0m\]\$ "'
Offline
You can try 'su -' or 'su -l' instead of 'su'.
According to 'su --help' this 'Clear environment, go to home dir, run shell as login shell'.
So /etc/profile is executed.
Offline
sì lo sapevo, ma il problema come anche Tu hai fatto notare, è che cambia posizione la shell (da pwd a home).
Non so come avevo fatto durante le prove passate che funzionava correttamente senza tanti problemi.
Pure qualche versione provvisoria di slitaz mi sembra che lo facesse, anche se non ti so dire quale fu esattamente.
-------------------------------------------------------------------------
Yes I knew that, but the problem as you also pointed out, is that the shell changes position (from pwd to home).
I don't know how I did it during the past tests that worked correctly without many problems.
Even some temporary version of slitaz seems to do it, but I can't tell you which one it was exactly.
Offline
Pages: 1
[ Generated in 0.016 seconds, 7 queries executed - Memory usage: 1.53 MiB (Peak: 1.77 MiB) ]