Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: prompt and ssh



On Tue, 19 May 2009, ugaciaka wrote:

I would like to change the type of zsh prompt the remote client (ssh): if I connected remotely show differently prompt...

What kind of condition if I can put on PS1?
==============

you can test for SSH_CONNECTION, SSH_CLIENT, or SSH_TTY on the far side. i would recommend SSH_CONNECTION.

my prompt <http://smasher.org/zsh/> does that, and displays the HOST if it's set on the machine. maybe that will give you some ideas...


--
        ...atom

 ________________________
 http://atom.smasher.org/
 762A 3B98 A3C3 96C9 C6B7 582A B88D 52E4 D9F5 7808
 -------------------------------------------------

	"America may be the best country in the world, but that's
	 kind of like being the valedictorian of summer school."
		-- Dennis Miller



Messages sorted by: Reverse Date, Date, Thread, Author