[zsh] Prevent glob expansion in history widget (#3855)

This commit is contained in:
Samara Jinnah 2024-06-13 03:43:33 +02:00 committed by GitHub
parent dca2262fe6
commit e023736c30
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -107,7 +107,7 @@ fi
# CTRL-R - Paste the selected command from history into the command line
fzf-history-widget() {
local selected num
setopt localoptions noglobsubst noposixbuiltins pipefail no_aliases 2> /dev/null
setopt localoptions noglobsubst noposixbuiltins pipefail no_aliases noglob 2> /dev/null
# Ensure the associative history array, which maps event numbers to the full
# history lines, is loaded, and that Perl is installed for multi-line output.
if zmodload -F zsh/parameter p:history 2>/dev/null && (( ${#commands[perl]} )); then