Linux Lite Forums

Development => Scripting and Bash => Topic started by: jacatone on January 07, 2016, 10:33:34 PM

Title: Need some scripting help
Post by: jacatone on January 07, 2016, 10:33:34 PM
I'm using the following command line to make my username in light red.

export PS1="\[\e[1;31m\][\[email protected]\h\w]\$ \[\e[0m\] "

When I try to make my change permanent in the .bashrc file, it just screws it up. What should I enter into the .bashrc file?

old command:
export PS1="\[\e[1;31m\][\[email protected]\h\w]\$ \[\e[0m\] "
Title: Re: Need some scripting help
Post by: miken242 on April 27, 2016, 11:48:36 AM
This can be done from the terminal menu
edit ....preferences
click on foreground and choose your colour
ok  saves it

hope this helps
mike
Title: Re: Need some scripting help
Post by: miken242 on April 28, 2016, 12:17:32 PM

LS_COLORS=$LS_COLORS:'di=0;36:fi=0;37' ; export LS_COLORS
#terminal prompt
 export PS1='\[\e[1;31m\]\u @ \h \w ->\n\[\e[1;36m\] \@ \d \$\[\e[m\] '
This is a line from my .bashrc file which produces a double line prompt with time and date underneath in cyan and the user name hostname in red

hope this is more useful to your script request

cheers mike