Hello,
-m (-ignoreMinorErrors) Ignore minor errors and warnings
How I can do so that errors are not displayed?
Thanks.
Use -q -q to hide all errors (and all other messages).
- Phil
Error messages are still displayed
C:\Users\Documents>exiftool -ImageWidth -q -if "$ImageWidth < 256" -ext jpg -ext png .
Image Width : 16
Error: File format error - ./out.jpg
Error: File format error - ./output_previewpath.jpg
Error: File format error - ./pp.jpg
notice that I used -q twice.
Hmmm. But you are right, two -q's only suppresses warnings. Errors may not be suppressed:
-q (-quiet)
Quiet processing. One -q suppresses normal informational
messages, and a second -q suppresses warnings as well. Error
messages can not be suppressed, although minor errors may be
downgraded to warnings with the -m option, which may then be
suppressed with "-q -q".
So try this instead:
exiftool -ImageWidth -if "$ImageWidth < 256" -ext jpg -ext png . 2>/dev/null
- Phil
Error messages are still displayed
C:\Users\Documents>exiftool -ImageWidth -if "$ImageWidth < 256" -ext jpg -ext png . 2>C:\tmp\basura.txt
======== ./copy.png
Image Width : 16
======== ./out.jpg
======== ./output_previewpath.jpg
======== ./pp.jpg
1 directories scanned
3 files failed condition
4 image files read
C:\Users\Documents>more C:\tmp\basura.txt
Error: File format error - ./out.jpg
Error: File format error - ./output_previewpath.jpg
Error: File format error - ./pp.jpg