zsh-users
 help / color / mirror / code / Atom feed
* How to stop dir expansion in the prompt?
@ 2014-11-04  3:23 Shiyao Ma
  2014-11-04  3:43 ` Bart Schaefer
  0 siblings, 1 reply; 7+ messages in thread
From: Shiyao Ma @ 2014-11-04  3:23 UTC (permalink / raw)
  To: zsh-users

Hi.
I am using this prompt:

PROMPT="%(?.${success_color}.${failure_color})${SSH_TTY:+[%n@%m]}%B%${max_path_chars}<...<"'${vcs_info_msg_0_%%}'"%<<%(!.${root_char}.${user_char})%b%f
"

The whole script is here: https://bpaste.net/show/52184a546984#56


If I cd to a directory like ~/.virtualenvs, the prompt will show as
~WORKON_HOME.
It's expanded to the environment variable WORKON_HOME.

I wonder, is there a option to disable the auto expansion?

If not, possible to modify the above prompt to show the real path?
Note, it's not a straightforward modification like ${PWD/#$HOME/~}
because vcs_info_msg_0 is inside and should be taken care of.



Thanks in advance.


Regards.




-- 

吾輩は猫である。ホームーページはhttp://introo.me。


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2014-11-05  1:27 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-11-04  3:23 How to stop dir expansion in the prompt? Shiyao Ma
2014-11-04  3:43 ` Bart Schaefer
2014-11-04  6:30   ` Shiyao Ma
2014-11-04  7:36     ` Bart Schaefer
2014-11-04  9:42       ` Shiyao Ma
2014-11-04 16:43         ` Bart Schaefer
2014-11-05  1:27           ` Shiyao Ma

Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).