From 5f2e2922ac2064afd4a69513227db1e4fe7de92d Mon Sep 17 00:00:00 2001 From: Luxferre Date: Fri, 13 Feb 2026 11:14:35 +0200 Subject: [PATCH] added gzip func to pngizer --- pngizer.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pngizer.sh b/pngizer.sh index 007255b..2cd980c 100755 --- a/pngizer.sh +++ b/pngizer.sh @@ -1,6 +1,6 @@ #!/bin/sh # PNGizer: convert any file into PNG image and back -# Depends on mktemp, tar, ImageMagick and pngcrush +# Depends on mktemp, tar, gzip, ImageMagick and pngcrush # Created by Luxferre in 2026, released into public domain # Convert any raw data file to PNG @@ -43,7 +43,7 @@ pngize() { [ -z "$2" ] && ofile="$1.png" temp_arch="$(mktemp)" # containerize the input - tar cf $temp_arch "$1" + GZIP=-9 tar czvf $temp_arch "$1" # run the conversion pngize_raw $temp_arch $ofile rm -f $temp_arch @@ -55,7 +55,7 @@ pngize() { unpngize() { temp_arch="$(mktemp)" unpngize_raw "$1" $temp_arch - tar xf $temp_arch + gzip -dcq $temp_arch | tar xvf - rm -f $temp_arch }