From: Oliver Kiddle <okiddle@yahoo.co.uk>
To: Timothy Luoma <luomat@peak.org>
Cc: zsh-users@sunsite.dk
Subject: Re: zsh prompt not updating until first 'chdir'
Date: Mon, 03 May 2004 08:55:22 +0200 [thread overview]
Message-ID: <3605.1083567322@trentino.logica.co.uk> (raw)
In-Reply-To: <9D0A9896-9C9A-11D8-B220-000D93AD26C8@peak.org>
Timothy Luoma wrote:
>
> > in your .zshrc directly, setopt prompt_subst, and forget about
> > resetting it every time you cd?
>
> PROMPT="
> ---------------------------------%t/%T ---------------------------------
> %S[OLDPWD: $dirstack[1]]
> [PWD: %~]%s
> $SHORT_HOST> "
>
> works great EXCEPT that OLDPWD doesn't get updated
Use single quotes instead of double quotes (and don't forget the
prompt_subst option). With double quotes, the variables are expanded
straightaway which is why they don't update.
Oliver
prev parent reply other threads:[~2004-05-03 6:57 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-05-01 14:53 Timothy J. Luoma
2004-05-01 16:14 ` Maurice
2004-05-01 17:52 ` Bart Schaefer
2004-05-03 1:30 ` Timothy J. Luoma
2004-05-01 23:32 ` Dan Nelson
2004-05-03 0:41 ` Timothy Luoma
2004-05-03 6:55 ` Oliver Kiddle [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=3605.1083567322@trentino.logica.co.uk \
--to=okiddle@yahoo.co.uk \
--cc=luomat@peak.org \
--cc=zsh-users@sunsite.dk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).