diff options
author | Tuowen Zhao <ztuowen@gmail.com> | 2020-11-21 14:57:26 -0700 |
---|---|---|
committer | Tuowen Zhao <ztuowen@gmail.com> | 2020-11-21 14:57:26 -0700 |
commit | 3aaa0bc62ece494dd2b6e47a191de79e562156f9 (patch) | |
tree | 53b623b60358bd9b8a5f9d267166f717e2f3947c /lib | |
parent | 058885f5263f29f046c96ea2ecf55e6dca3ed321 (diff) | |
parent | 88b3f028f4a2ffa4f3853a11e4b8e0d78008ca34 (diff) | |
download | zsh-3aaa0bc62ece494dd2b6e47a191de79e562156f9.tar.gz zsh-3aaa0bc62ece494dd2b6e47a191de79e562156f9.tar.bz2 zsh-3aaa0bc62ece494dd2b6e47a191de79e562156f9.zip |
Merge remote-tracking branch 'origin/master'
Diffstat (limited to 'lib')
-rw-r--r-- | lib/functions.zsh | 1 | ||||
-rw-r--r-- | lib/history.zsh | 4 |
2 files changed, 4 insertions, 1 deletions
diff --git a/lib/functions.zsh b/lib/functions.zsh index 58f0e3fb0..15526cd5f 100644 --- a/lib/functions.zsh +++ b/lib/functions.zsh @@ -134,6 +134,7 @@ zmodload zsh/langinfo # -P causes spaces to be encoded as '%20' instead of '+' function omz_urlencode() { emulate -L zsh + local -a opts zparseopts -D -E -a opts r m P local in_str=$1 diff --git a/lib/history.zsh b/lib/history.zsh index 8d922a30b..794076904 100644 --- a/lib/history.zsh +++ b/lib/history.zsh @@ -6,7 +6,8 @@ function omz_history { if [[ -n "$clear" ]]; then # if -c provided, clobber the history file echo -n >| "$HISTFILE" - echo >&2 History file deleted. Reload the session to see its effects. + fc -p "$HISTFILE" + echo >&2 History file deleted. elif [[ -n "$list" ]]; then # if -l provided, run as if calling `fc' directly builtin fc "$@" @@ -36,3 +37,4 @@ setopt hist_expire_dups_first # delete duplicates first when HISTFILE size excee setopt hist_ignore_dups # ignore duplicated commands history list setopt hist_ignore_space # ignore commands that start with space setopt hist_verify # show command with history expansion to user before running it +setopt share_history # share command history data |