From 1c6f6df2b3ae4a13d89242964ca3dbd3c146d1fe Mon Sep 17 00:00:00 2001 From: Elis Axelsson Date: Fri, 6 May 2016 16:15:47 +0200 Subject: [PATCH] Change abbr to allow non-letter keys (#2996) --- share/functions/abbr.fish | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/functions/abbr.fish b/share/functions/abbr.fish index bb50ec023..8606f84b2 100644 --- a/share/functions/abbr.fish +++ b/share/functions/abbr.fish @@ -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