Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: _time_zone gives me candidates other than timezones



> 2022/03/30 9:12, Aaron Schrab <aaron@xxxxxxxxxx> wrote:
> 
> While I don't think I've ever really needed to use zoneinfo entries from those directories, I'd certainly prefer they be offered for completion.

How about this?

diff --git a/Completion/Unix/Type/_time_zone b/Completion/Unix/Type/_time_zone
index cd924bbc7..c437252a8 100644
--- a/Completion/Unix/Type/_time_zone
+++ b/Completion/Unix/Type/_time_zone
@@ -6,4 +6,4 @@ if (( ! $+_zoneinfo_dirs )); then
   _zoneinfo_dirs=( /usr/{share,lib,share/lib}/{zoneinfo*,locale/TZ}(/) )
 fi
 
-_wanted time-zones expl 'time zone' _files -W _zoneinfo_dirs "$@" -
+_wanted time-zones expl 'time zone' _files -g '[A-Z]*' -W _zoneinfo_dirs "$@" -







Messages sorted by: Reverse Date, Date, Thread, Author