瀏覽代碼

Escape the prefix passed into the match_prev_cmd strategy

pull/180/head
Eric Freese 7 年之前
父節點
當前提交
50e6832b8c
共有 2 個文件被更改,包括 2 次插入2 次删除
  1. +1
    -1
      src/strategies/match_prev_cmd.zsh
  2. +1
    -1
      zsh-autosuggestions.zsh

+ 1
- 1
src/strategies/match_prev_cmd.zsh 查看文件

@ -21,7 +21,7 @@
# `HIST_EXPIRE_DUPS_FIRST`.
_zsh_autosuggest_strategy_match_prev_cmd() {
local prefix="$1"
local prefix="${1//(#m)[\\()\[\]|*?~]/\\$MATCH}"
# Get all history event numbers that correspond to history
# entries that match pattern $prefix*

+ 1
- 1
zsh-autosuggestions.zsh 查看文件

@ -453,7 +453,7 @@ _zsh_autosuggest_strategy_default() {
# `HIST_EXPIRE_DUPS_FIRST`.
_zsh_autosuggest_strategy_match_prev_cmd() {
local prefix="$1"
local prefix="${1//(#m)[\\()\[\]|*?~]/\\$MATCH}"
# Get all history event numbers that correspond to history
# entries that match pattern $prefix*

Loading…
取消
儲存