When convert
ing an image, ImageMagick's default behavior seems to be to overwrite any existing file. Is it possible to prevent this? I'm looking for something similar to Wget's --no-clobber
download option. I've gone through ImageMagick's list of command-line options, and the closest option I could find was -update
, but this can only detect if an input file is changed.
Here's an example of what I'd like to accomplish: On the first run, convert input.jpg output.png
produces an output.png
that does not already exist, and then on the second run, convert input.jpg output.png
detects that output.png
already exists and does not overwrite it.