diff options
author | Aloxaf <bailong104@gmail.com> | 2020-01-05 00:15:24 +0800 |
---|---|---|
committer | Marc Cornellà <marc.cornella@live.com> | 2020-01-04 17:15:24 +0100 |
commit | 78b07e92fd4a3a5e1f92ee4e3d680c39b72c2245 (patch) | |
tree | cfbb3b487f2caf3a58aba135946faebcde902008 /plugins/extract/extract.plugin.zsh | |
parent | ca627655dbd1d110dbea34ec4a8c1964a1da83d2 (diff) | |
download | zsh-78b07e92fd4a3a5e1f92ee4e3d680c39b72c2245.tar.gz zsh-78b07e92fd4a3a5e1f92ee4e3d680c39b72c2245.tar.bz2 zsh-78b07e92fd4a3a5e1f92ee4e3d680c39b72c2245.zip |
extract: add lz4 support (#8510)
Diffstat (limited to 'plugins/extract/extract.plugin.zsh')
-rw-r--r-- | plugins/extract/extract.plugin.zsh | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/plugins/extract/extract.plugin.zsh b/plugins/extract/extract.plugin.zsh index 349c9a776..a5594b81a 100644 --- a/plugins/extract/extract.plugin.zsh +++ b/plugins/extract/extract.plugin.zsh @@ -46,11 +46,13 @@ extract() { || zstdcat "$1" | tar xvf - ;; (*.tar) tar xvf "$1" ;; (*.tar.lz) (( $+commands[lzip] )) && tar xvf "$1" ;; + (*.tar.lz4) lz4 -c -d "$1" | tar xvf - ;; (*.tar.lrz) (( $+commands[lrzuntar] )) && lrzuntar "$1" ;; (*.gz) (( $+commands[pigz] )) && pigz -dk "$1" || gunzip -k "$1" ;; (*.bz2) bunzip2 "$1" ;; (*.xz) unxz "$1" ;; (*.lrz) (( $+commands[lrunzip] )) && lrunzip "$1" ;; + (*.lz4) lz4 -d "$1" ;; (*.lzma) unlzma "$1" ;; (*.z) uncompress "$1" ;; (*.zip|*.war|*.jar|*.sublime-package|*.ipsw|*.xpi|*.apk|*.aar|*.whl) unzip "$1" -d $extract_dir ;; |