batpipe: Fix viewing listings in zip files

This commit is contained in:
Ethan P 2021-03-24 20:09:04 -07:00
parent 988780bce9
commit 0d2e999b2a
No known key found for this signature in database
GPG Key ID: 6963FD04F6CF35EA

View File

@ -161,7 +161,7 @@ viewer_unzip_supports() {
}
viewer_unzip_process() {
if [[ -n "$1" ]]; then
if [[ -n "$2" ]]; then
unzip -p "$1" "$2" | bat_if_not_bat --file-name="$1/$2"
else
batpipe_header "Viewing contents of archive: %{PATH}%s" "$1"