mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-26 12:53:13 +00:00
Change abbr to allow non-letter keys (#2996)
(cherry picked from commit 1c6f6df2b3
)
This commit is contained in:
parent
49838c768d
commit
8ec81393a3
1 changed files with 1 additions and 1 deletions
|
@ -85,7 +85,7 @@ function abbr --description "Manage abbreviations"
|
|||
set key $kv[1]
|
||||
set value $kv[2]
|
||||
# ensure the key contains at least one non-space character
|
||||
if not string match -qr "\w" -- $key
|
||||
if not string match -qr "[^\s]" -- $key
|
||||
printf ( _ "%s: abbreviation must have a non-empty key\n" ) abbr >&2
|
||||
return 1
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue