Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 5 May 2011 14:37:48 +0200
From:      Polytropon <freebsd@edvax.de>
To:        pwnedomina <pwnedomina@gmail.com>
Cc:        questions@freebsd.org
Subject:   Re: rox-fm
Message-ID:  <20110505143748.4be94f6f.freebsd@edvax.de>
In-Reply-To: <4DC27128.8040508@gmail.com>
References:  <4DC1BEA8.6030108@gmail.com> <20110504224931.9ffd5682.dcdowse@gmx.net> <4DC1E23E.3020001@gmail.com> <20110505014556.50dcea0e.dcdowse@gmx.net> <BANLkTi=Csvs+3C7-XJGUDn43Jzf-JNZZ4g@mail.gmail.com> <4DC27128.8040508@gmail.com>

Next in thread | Previous in thread | Raw E-Mail | Index | Archive | Help
On Thu, 05 May 2011 09:43:04 +0000, pwnedomina <pwnedomina@gmail.com> wrote:
> ok, ive choosen "reply to all". my question now is
> i have setted the command prompt to
> "|[%n@%m:%c]%#"
> but i intend to place color red in the [] brackets, how can i accomplish 
> this?|

It looks like you are configuring a C shell prompt, correct?
Make sure you have the following settings in ~/.cshrc (or in
/ect/csh.cshrc, if you want a global setting):

	set promptchars = "%#"
	set prompt = "%n@%m:%~%# "

This would give you the STANDARD prompt - note the space after
the prompt character and the absense of the brackets.

You want red color - I'm not sure if this is supported in csh.
At least I know that bold printing is possible. Have a look
at this:

	set prompt = "[%B%n@%m:%~%b]%# "

This uses %B and %b to switch on and off bold printing. Refer
to "man csh", section "Special shell variables" and scroll
down to "prompt" - there are some more special settings to
customize the prompt. It mentions "%{string%}" for escape
sequences and can MAYBE be used for changing color.

Is the pipe character at the beginning of the prompt intended?
If yes, use this:

	set prompt = "|[%B%n@%m:%~%b]%# "

I've kept the space at the end of the prompt for better
readability. Remove it if desired.




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <http://docs.FreeBSD.org/cgi/mid.cgi?20110505143748.4be94f6f.freebsd>