add plugin 'universalarchive()' to conveniently compress files

This commit is contained in:
Enno Nagel 2018-05-21 12:27:55 -03:00
commit 1c389ea4e5
3 changed files with 115 additions and 0 deletions

View file

@ -0,0 +1,7 @@
#compdef universalarchive
#autoload
_arguments \
'(-r --remove)'{-r,--remove}'[Remove archive.]' \
"*::archive file:_files -g '(#i)*.(7z|Z|bz2|gz|lzma|rar|tar|tar.bz2|tar.gz|tar.xz|tar.zma|tbz|tbz2|tgz|tlz|txz|xz|zip)(-.)'" \
&& return 0