From 26d04aa7dccb78b7e7d3cab1002358fa08d40a8b Mon Sep 17 00:00:00 2001 From: Jan Huwald Date: Wed, 5 Nov 2014 15:51:13 +0100 Subject: simplify: which already checks for executability diff --git a/anondcim b/anondcim index 473b629..7a05970 100755 --- a/anondcim +++ b/anondcim @@ -20,7 +20,7 @@ rand() { [ $# -gt 0 ] || die "Usage: $0 [-p image_prefix] [-s destination_size (absolute or percentage)] [-d destination_directory] imagefile(s)" -[ ! -x "$(which convert)" ] && die "ImageMagick (convert, identify) is not installed" +which convert 2>/dev/null || die "ImageMagick (convert, identify) is not installed" which jhead 2>/dev/null || which exiftool 2>/dev/null || die "jhead or exiftool has to be installed" # set default values -- cgit v0.10.1