From: Peter Stephenson <pws@csr.com>
To: Zsh hackers list <zsh-workers@sunsite.dk>
Subject: Re: DEBUG_CMD_LINE (Was Re: PATCH: skip command from debug trap)
Date: Thu, 7 Aug 2008 13:06:56 +0100 [thread overview]
Message-ID: <20080807130656.34179090@news01> (raw)
In-Reply-To: <20080807104030.GA7373@sc.homeunix.net>
On Thu, 7 Aug 2008 11:40:30 +0100
Stephane Chazelas <Stephane_Chazelas@yahoo.fr> wrote:
> On Thu, Aug 07, 2008 at 11:14:38AM +0100, Peter Stephenson wrote:
> [...]
> > > BTW, shouldn't PROMPT_SUBST be enabled by default in sh and ksh
> > > emulation?
> >
> > If they do that, then presumably yes.
> [...]
>
> It's required by SUSv3 for non-priviledged users for systems
> supporting the User Portability Utilities option (so include the
> sh of Unix conformant systems, but not necessarily POSIX
> conformant ones I suppose).
Looks like it's already set up for ksh. It should probably be turned on
for other Bourne-style shells. I suppose it wasn't done originally because
at the time that meant old-fashioned, fairly limited Bourne shells, but
nowadays it doesn't. "promptvars" is on by default in bash.
Index: Doc/Zsh/options.yo
===================================================================
RCS file: /cvsroot/zsh/zsh/Doc/Zsh/options.yo,v
retrieving revision 1.61
diff -u -r1.61 options.yo
--- Doc/Zsh/options.yo 12 Jun 2008 13:45:05 -0000 1.61
+++ Doc/Zsh/options.yo 7 Aug 2008 12:04:46 -0000
@@ -1009,7 +1009,7 @@
)
pindex(PROMPT_SUBST)
cindex(prompt, parameter expansion)
-item(tt(PROMPT_SUBST) <K>)(
+item(tt(PROMPT_SUBST) <K> <S>)(
If set, em(parameter expansion), em(command substitution) and
em(arithmetic expansion) are performed in prompts. Substitutions
within prompts do not affect the command status.
Index: Src/options.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/options.c,v
retrieving revision 1.43
diff -u -r1.43 options.c
--- Src/options.c 31 Jul 2008 08:44:21 -0000 1.43
+++ Src/options.c 7 Aug 2008 12:04:47 -0000
@@ -198,7 +198,7 @@
{{NULL, "promptcr", OPT_ALL}, PROMPTCR},
{{NULL, "promptpercent", OPT_NONBOURNE}, PROMPTPERCENT},
{{NULL, "promptsp", OPT_ALL}, PROMPTSP},
-{{NULL, "promptsubst", OPT_KSH}, PROMPTSUBST},
+{{NULL, "promptsubst", OPT_BOURNE}, PROMPTSUBST},
{{NULL, "pushdignoredups", OPT_EMULATE}, PUSHDIGNOREDUPS},
{{NULL, "pushdminus", OPT_EMULATE}, PUSHDMINUS},
{{NULL, "pushdsilent", 0}, PUSHDSILENT},
--
Peter Stephenson <pws@csr.com> Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK Tel: +44 (0)1223 692070
next prev parent reply other threads:[~2008-08-07 12:08 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-08-06 21:19 Rocky Bernstein
2008-08-07 8:54 ` Peter Stephenson
2008-08-07 9:31 ` Stephane Chazelas
2008-08-07 10:14 ` Peter Stephenson
2008-08-07 10:40 ` Stephane Chazelas
2008-08-07 12:06 ` Peter Stephenson [this message]
2008-08-07 13:37 ` Rocky Bernstein
2008-08-07 15:10 ` Bart Schaefer
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=20080807130656.34179090@news01 \
--to=pws@csr.com \
--cc=zsh-workers@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).