From 7131b3d6ee5ea75dba1c4d5337cbd61b9fa4c4e0 Mon Sep 17 00:00:00 2001 From: Jakub Wilk Date: Sat, 21 Jul 2018 12:03:12 +0200 Subject: [PATCH] Use printf(1) instead of non-portable "/bin/echo -ne" --- test_comp.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test_comp.sh b/test_comp.sh index ae832e2..44edefd 100755 --- a/test_comp.sh +++ b/test_comp.sh @@ -16,17 +16,17 @@ for a in `convert -list compress`; do echo "encode:\t$a" convert "$1" -compress $a "`basename $1 .jpg`.pdf" pdfimages "`basename $1 .jpg`.pdf" "`basename $1 .jpg`" - /bin/echo -ne "diff:\t" + printf "diff:\t" diff=`compare -metric AE "$1" "\`basename $1 .jpg\`-000.ppm" null: 2>&1` if [ "$diff" != "0" ]; then echo "lossy" else echo "lossless" fi - /bin/echo -ne "size:\t" + printf "size:\t" pdfsize=`stat -c "%s" "\`basename $1 .jpg\`.pdf"` echo "scale=1;$pdfsize/$imsize" | bc - /bin/echo -ne "pdf:\t" + printf "pdf:\t" grep --max-count=1 --text /Filter "`basename $1 .jpg`.pdf" echo done