f8180c3a64754057d696a4fb1cf3639c394377b9

Author
Marc Cornellà <marc.cornella@live.com>
Committer
Marc Cornellà <marc.cornella@live.com>
Date

Message

Allow overriding -l flag in history

Diff

 1diff --git a/lib/history.zsh b/lib/history.zsh
 2index 21e9c7563bc596cc9de3ec625d926eaaf20e9d1a..e6c94fcc08df8a49e481268bb13491327fddc882 100644
 3--- a/lib/history.zsh
 4+++ b/lib/history.zsh
 5@@ -5,6 +5,8 @@ function omz_history {
 6   if [[ "${@[(i)-c]}" -le $# ]]; then
 7     echo -n >| "$HISTFILE"
 8     echo >&2 History file deleted. Reload the session to see its effects.
 9+  elif [[ "${@[(i)-l]}" -le $# ]]; then
10+    builtin fc "$@"
11   else
12     builtin fc "$@" -l 1
13   fi