summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBarton E. Schaefer <schaefer@zsh.org>2014-02-17 09:57:05 -0800
committerBarton E. Schaefer <schaefer@zsh.org>2014-02-17 09:57:05 -0800
commit76ab661df3015f5adc10ff58ba5ea773901753bf (patch)
tree909e6f4b1d104a284819dbefeb73a2665390e397
parent956d35ef12a061ec41396b1e0469bd166f6ef007 (diff)
downloadzsh-76ab661df3015f5adc10ff58ba5ea773901753bf.tar.gz
zsh-76ab661df3015f5adc10ff58ba5ea773901753bf.zip
unposted: document interactions of "fc -R" etc. with "fc -l" and $HISTCMD
-rw-r--r--ChangeLog5
-rw-r--r--Doc/Zsh/builtins.yo3
-rw-r--r--Doc/Zsh/params.yo7
3 files changed, 12 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index cef2af0ce..ef4b622e7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2014-02-17 Barton E. Schaefer <schaefer@zsh.org>
+
+ * unposted (users/18468): Doc/Zsh/builtins.yo, Doc/Zsh/params.yo:
+ document interactions of "fc -R" etc. with "fc -l" and $HISTCMD
+
2014-02-15 Barton E. Schaefer <schaefer@zsh.org>
* 32389 (with Jun Takimoto): Test/X02zlevi.ztst, Test/comptest:
diff --git a/Doc/Zsh/builtins.yo b/Doc/Zsh/builtins.yo
index 3c2d5e504..9905ab5ca 100644
--- a/Doc/Zsh/builtins.yo
+++ b/Doc/Zsh/builtins.yo
@@ -683,6 +683,9 @@ If var(first) is not specified, it will be set to -1 (the most recent
event), or to -16 if the tt(-l) flag is given.
If var(last) is not specified, it will be set to var(first),
or to -1 if the tt(-l) flag is given.
+However, if the current event has added entries to the history with
+`tt(print -s)' or `tt(fc -R)', then the default var(last) for tt(-l)
+includes all new history entries since the current event began.
The flag tt(-r) reverses the order of the commands and the
flag tt(-n) suppresses command numbers when listing.
diff --git a/Doc/Zsh/params.yo b/Doc/Zsh/params.yo
index 935fd5d86..cf2ad34d4 100644
--- a/Doc/Zsh/params.yo
+++ b/Doc/Zsh/params.yo
@@ -599,9 +599,10 @@ group ID by `tt(LPAR()GID=)var(gid)tt(; command+RPAR())'
)
vindex(HISTCMD)
item(tt(HISTCMD))(
-The current history line number in an interactive shell, in other
-words the line number for the command that caused tt($HISTCMD)
-to be read.
+The current history event number in an interactive shell, in other
+words the event number for the command that caused tt($HISTCMD)
+to be read. If the current history event modifies the history,
+tt(HISTCMD) changes to the new maximum history event number.
)
vindex(HOST)
item(tt(HOST))(