mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-26 04:43:10 +00:00
Change abbr to allow non-letter keys (#2996)
This commit is contained in:
parent
bc6cc4c105
commit
1c6f6df2b3
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