mirror of
git://git.code.sf.net/p/zsh/code
synced 2025-10-13 11:21:13 +02:00
20126: tidy up before 4.2.1
20127: tweaked version of Wayne's patch to reexand prompts
This commit is contained in:
parent
e9fa060671
commit
8784bbe97c
16 changed files with 65 additions and 12 deletions
|
@ -1,6 +1,7 @@
|
||||||
DISTFILES_SRC='
|
DISTFILES_SRC='
|
||||||
.cvsignore .distfiles .preconfig Makefile.in
|
.cvsignore .distfiles .preconfig Makefile.in
|
||||||
ChangeLog ChangeLog-3.1 ChangeLog.3.0 INSTALL LICENCE META-FAQ README
|
ChangeLog
|
||||||
|
FEATURES INSTALL LICENCE MACHINES META-FAQ NEWS README
|
||||||
aclocal.m4 aczsh.m4 configure.ac
|
aclocal.m4 aczsh.m4 configure.ac
|
||||||
configure config.h.in stamp-h.in
|
configure config.h.in stamp-h.in
|
||||||
config.guess config.sub install-sh mkinstalldirs
|
config.guess config.sub install-sh mkinstalldirs
|
||||||
|
|
12
ChangeLog
12
ChangeLog
|
@ -1,5 +1,17 @@
|
||||||
2004-07-02 Peter Stephenson <pws@csr.com>
|
2004-07-02 Peter Stephenson <pws@csr.com>
|
||||||
|
|
||||||
|
* 20127: Doc/Zsh/zle.yo, Src/Zle/zle_main.c,
|
||||||
|
Src/Zle/zle_refresh.c: slightly tweaked version of Wayne's
|
||||||
|
patch in users/7652 which only reexpands the prompt when
|
||||||
|
the commandline was trashed by output.
|
||||||
|
|
||||||
|
* 20126, with modifications: .distfiles, ChangeLog-3.1,
|
||||||
|
ChangeLog-4.1, ChangeLog.3.0, FEATURES, INSTALL, MACHINES,
|
||||||
|
NEWS, README, Etc/.distfiles, Etc/ChangeLog-3.1,
|
||||||
|
Etc/ChangeLog-4.1, Etc/FAQ.yo, Etc/FEATURES, Etc/MACHINES,
|
||||||
|
Etc/NEWS, Test/.distfiles, Etc/ChangeLog-3.0: tidy up
|
||||||
|
ready for 4.2.1
|
||||||
|
|
||||||
* 20125: Doc/Zsh/jobs.yo: say where the output for job
|
* 20125: Doc/Zsh/jobs.yo: say where the output for job
|
||||||
notifications goes.
|
notifications goes.
|
||||||
|
|
||||||
|
|
|
@ -1745,6 +1745,11 @@ does not reflect changes to the prompt variables themselves, only changes
|
||||||
in the expansion of the values (for example, changes in time or
|
in the expansion of the values (for example, changes in time or
|
||||||
directory, or changes to the value of variables referred to by the
|
directory, or changes to the value of variables referred to by the
|
||||||
prompt).
|
prompt).
|
||||||
|
|
||||||
|
Otherwise, the prompt is only expaned each time zle starts, and
|
||||||
|
when the display as been interrupted by output from another part of the
|
||||||
|
shell (such as a job notification) which causes the command line to be
|
||||||
|
reprinted.
|
||||||
)
|
)
|
||||||
tindex(send-break)
|
tindex(send-break)
|
||||||
item(tt(send-break) (^G ESC-^G) (unbound) (unbound))(
|
item(tt(send-break) (^G ESC-^G) (unbound) (unbound))(
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
DISTFILES_SRC='
|
DISTFILES_SRC='
|
||||||
.cvsignore .distfiles Makefile.in
|
.cvsignore .distfiles Makefile.in
|
||||||
BUGS CONTRIBUTORS FAQ FAQ.yo FEATURES MACHINES NEWS STD-TODO TODO
|
BUGS CONTRIBUTORS FAQ FAQ.yo STD-TODO TODO
|
||||||
FTP-README pubring.pgp
|
FTP-README pubring.pgp
|
||||||
completion-style-guide zsh-development-guide
|
completion-style-guide zsh-development-guide
|
||||||
changelog2html.pl
|
changelog2html.pl
|
||||||
|
ChangeLog-3.1 ChangeLog-3.0 ChangeLog-4.1
|
||||||
'
|
'
|
||||||
|
|
|
@ -275,7 +275,7 @@ sect(On what machines will it run?)
|
||||||
mechanism. This considerably increases flexibility over the old
|
mechanism. This considerably increases flexibility over the old
|
||||||
`buildzsh' mechanism. Consequently, zsh should compile and run on
|
`buildzsh' mechanism. Consequently, zsh should compile and run on
|
||||||
any modern version of UNIX, and a great many not-so-modern versions
|
any modern version of UNIX, and a great many not-so-modern versions
|
||||||
too. The file Etc/MACHINES in the distribution has more details.
|
too. The file MACHINES in the distribution has more details.
|
||||||
|
|
||||||
There are also now separate ports for Windows and OS/2, see `Where
|
There are also now separate ports for Windows and OS/2, see `Where
|
||||||
do I get it' below.
|
do I get it' below.
|
||||||
|
@ -288,7 +288,7 @@ sect(On what machines will it run?)
|
||||||
|
|
||||||
To get it to work, retrieve the source distribution (see question
|
To get it to work, retrieve the source distribution (see question
|
||||||
link(1.6)(16)), un-gzip it, un-tar it and read the INSTALL file in the top
|
link(1.6)(16)), un-gzip it, un-tar it and read the INSTALL file in the top
|
||||||
directory. Also read the Etc/MACHINES file for up-to-date
|
directory. Also read the MACHINES file for up-to-date
|
||||||
information on compilation on certain architectures.
|
information on compilation on certain architectures.
|
||||||
|
|
||||||
mybf(Note for users of nawk) (The following information comes from Zoltan
|
mybf(Note for users of nawk) (The following information comes from Zoltan
|
||||||
|
|
4
INSTALL
4
INSTALL
|
@ -15,7 +15,7 @@ MAKING AND INSTALLING
|
||||||
Check MACHINES File
|
Check MACHINES File
|
||||||
-------------------
|
-------------------
|
||||||
|
|
||||||
Check the file MACHINES in the subdirectory Etc to see the architectures
|
Check the file MACHINES in the top directory to see the architectures
|
||||||
that zsh is known to compile on, as well as any special instructions
|
that zsh is known to compile on, as well as any special instructions
|
||||||
for your particular architecture. Most architectures will not require any
|
for your particular architecture. Most architectures will not require any
|
||||||
special instructions.
|
special instructions.
|
||||||
|
@ -243,7 +243,7 @@ which reduce memory usage on some systems. To use these, add the option
|
||||||
--enable-zsh-mem
|
--enable-zsh-mem
|
||||||
when invoking "configure".
|
when invoking "configure".
|
||||||
|
|
||||||
You should check Etc/MACHINES to see if there are specific recommendations
|
You should check MACHINES to see if there are specific recommendations
|
||||||
about using the zsh malloc routines on your particular architecture.
|
about using the zsh malloc routines on your particular architecture.
|
||||||
|
|
||||||
Debugging Routines
|
Debugging Routines
|
||||||
|
|
|
@ -5,6 +5,23 @@ CHANGES FROM PREVIOUS VERSIONS OF ZSH
|
||||||
Changes since zsh version 4.2.0
|
Changes since zsh version 4.2.0
|
||||||
-------------------------------
|
-------------------------------
|
||||||
|
|
||||||
|
- A new `try block' and `always block' syntax has been introduced
|
||||||
|
to make it easier to ensure the shell runs important tidy-up code
|
||||||
|
in the event of an error. It also runs after a break, continue, or
|
||||||
|
return, including a return forced by the ERR_RETURN option,
|
||||||
|
but not an exit, which is immediate). The syntax is:
|
||||||
|
`{' try-block-list `}' `always' `{' always-block-list `}'
|
||||||
|
where no newline or semicolon may appear between `}' and `always'.
|
||||||
|
This is compatible with all previous valid zsh syntax as an `always'
|
||||||
|
at that point used to be a syntax error. For example,
|
||||||
|
{ echo Code run in current shell } always { echo Tidy-up code }
|
||||||
|
|
||||||
|
- A new zle widget reset-prompt has been added to re-expand the current
|
||||||
|
prompt. Note that this does not take account of changes to the
|
||||||
|
prompt variables themselves, only the expansion of the text. The
|
||||||
|
same effect is now forced by a job change notification, making
|
||||||
|
the %j prompt escape and %(j..) ternary expression more useful.
|
||||||
|
|
||||||
- The zftp module supports ports following the hostname in the normal suffix
|
- The zftp module supports ports following the hostname in the normal suffix
|
||||||
notation, `host:port'. This requires IPv6 colon-style addresses to be
|
notation, `host:port'. This requires IPv6 colon-style addresses to be
|
||||||
specified in suitably quoted square brackets, for example:
|
specified in suitably quoted square brackets, for example:
|
14
README
14
README
|
@ -5,25 +5,33 @@ THE Z SHELL (ZSH)
|
||||||
Version
|
Version
|
||||||
-------
|
-------
|
||||||
|
|
||||||
This is zsh version 4.2.0. This is a stable release.
|
This is zsh version 4.2.1. This is a stable release.
|
||||||
|
|
||||||
Installing Zsh
|
Installing Zsh
|
||||||
--------------
|
--------------
|
||||||
|
|
||||||
The instructions for compiling zsh are in the file INSTALL. You should
|
The instructions for compiling zsh are in the file INSTALL. You should
|
||||||
also check the file MACHINES in the subdirectory Etc to see if there
|
also check the file MACHINES in the top directory to see if there
|
||||||
are any special instructions for your particular architecture.
|
are any special instructions for your particular architecture.
|
||||||
|
|
||||||
Features
|
Features
|
||||||
--------
|
--------
|
||||||
|
|
||||||
Zsh is a shell with lots of features. For a list of some of these, see the
|
Zsh is a shell with lots of features. For a list of some of these, see the
|
||||||
file Etc/FEATURES, and for the latest changes see Etc/NEWS. For more
|
file FEATURES, and for the latest changes see NEWS. For more
|
||||||
details, see the documentation.
|
details, see the documentation.
|
||||||
|
|
||||||
Possible incompatibilities
|
Possible incompatibilities
|
||||||
---------------------------
|
---------------------------
|
||||||
|
|
||||||
|
Currently the only known incompatibilities between 4.2.0 and later
|
||||||
|
versions are minor: IPv6 addresses must be specified in
|
||||||
|
square brackets in the zftp module and function system; special
|
||||||
|
traps for pseudosignals ZERR, DEBUG and EXIT are no longer executed
|
||||||
|
inside other traps (users may well have assumed this was the case anyway
|
||||||
|
since the behaviour was not explicity documented). See the NEWS file for
|
||||||
|
more detail.
|
||||||
|
|
||||||
Some particular differences you may notice since version 4.0:
|
Some particular differences you may notice since version 4.0:
|
||||||
|
|
||||||
The bash-compatibility zle functions described in the zshcontrib manual
|
The bash-compatibility zle functions described in the zshcontrib manual
|
||||||
|
|
|
@ -1311,14 +1311,20 @@ recursiveedit(UNUSED(char **args))
|
||||||
}
|
}
|
||||||
|
|
||||||
/**/
|
/**/
|
||||||
int
|
void
|
||||||
resetprompt(UNUSED(char **args))
|
reexpandprompt(void)
|
||||||
{
|
{
|
||||||
free(lpromptbuf);
|
free(lpromptbuf);
|
||||||
lpromptbuf = promptexpand(raw_lp, 1, NULL, NULL);
|
lpromptbuf = promptexpand(raw_lp, 1, NULL, NULL);
|
||||||
free(rpromptbuf);
|
free(rpromptbuf);
|
||||||
rpromptbuf = promptexpand(raw_rp, 1, NULL, NULL);
|
rpromptbuf = promptexpand(raw_rp, 1, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**/
|
||||||
|
int
|
||||||
|
resetprompt(UNUSED(char **args))
|
||||||
|
{
|
||||||
|
reexpandprompt();
|
||||||
return redisplay(NULL);
|
return redisplay(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -291,7 +291,9 @@ zrefresh(void)
|
||||||
unsigned char *tmpline; /* line with added pre/post text */
|
unsigned char *tmpline; /* line with added pre/post text */
|
||||||
int tmpcs, tmpll; /* ditto cursor position and line length */
|
int tmpcs, tmpll; /* ditto cursor position and line length */
|
||||||
int tmpalloced; /* flag to free tmpline when finished */
|
int tmpalloced; /* flag to free tmpline when finished */
|
||||||
|
|
||||||
|
if (trashedzle)
|
||||||
|
reexpandprompt();
|
||||||
|
|
||||||
/* If this is called from listmatches() (indirectly via trashzle()), and *
|
/* If this is called from listmatches() (indirectly via trashzle()), and *
|
||||||
* that was called from the end of zrefresh(), then we don't need to do *
|
* that was called from the end of zrefresh(), then we don't need to do *
|
||||||
|
|
|
@ -9,5 +9,6 @@ A04redirect.ztst D01prompt.ztst V02zregexparse.ztst
|
||||||
A05execution.ztst D02glob.ztst Y01completion.ztst
|
A05execution.ztst D02glob.ztst Y01completion.ztst
|
||||||
D06subscript.ztst V01zmodload.ztst E01options.ztst
|
D06subscript.ztst V01zmodload.ztst E01options.ztst
|
||||||
B02typeset.ztst B03print.ztst A06assign.ztst B04read.ztst
|
B02typeset.ztst B03print.ztst A06assign.ztst B04read.ztst
|
||||||
|
V03mathfunc.ztst
|
||||||
README
|
README
|
||||||
'
|
'
|
||||||
|
|
Loading…
Reference in a new issue