summaryrefslogtreecommitdiff
path: root/lib/history.zsh
diff options
context:
space:
mode:
authorMarc Cornellà <marc.cornella@live.com>2014-12-18 20:36:56 +0100
committerMarc Cornellà <marc.cornella@live.com>2018-04-22 15:32:30 +0200
commitf8180c3a64754057d696a4fb1cf3639c394377b9 (patch)
treebee5c04dc1bce73be5151ab31d529562d8f92a21 /lib/history.zsh
parent03758416fe99f0f1cb9f19ad1a7846de1b02f21a (diff)
downloadzsh-f8180c3a64754057d696a4fb1cf3639c394377b9.tar.gz
zsh-f8180c3a64754057d696a4fb1cf3639c394377b9.tar.bz2
zsh-f8180c3a64754057d696a4fb1cf3639c394377b9.zip
Allow overriding -l flag in history
Diffstat (limited to 'lib/history.zsh')
-rw-r--r--lib/history.zsh2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/history.zsh b/lib/history.zsh
index 21e9c7563..e6c94fcc0 100644
--- a/lib/history.zsh
+++ b/lib/history.zsh
@@ -5,6 +5,8 @@ function omz_history {
if [[ "${@[(i)-c]}" -le $# ]]; then
echo -n >| "$HISTFILE"
echo >&2 History file deleted. Reload the session to see its effects.
+ elif [[ "${@[(i)-l]}" -le $# ]]; then
+ builtin fc "$@"
else
builtin fc "$@" -l 1
fi