I have a folder of images. All have the JPG extension but when running file against a few, they're coming back as bitmap e.g.25818.jpg: PC bitmap, Windows 3.x format, 357 x 500 x 24My question is how would I loop through all the images, check whether it's a bitmap file and then convert it to a JPG?The command I'd use in a single case would be the following but not sure how I'd do the checks and loop through the filesmogrify -format jpg 25818.jpgNewbie :-(Thanks
Loop through files and convert BMP files to JPG
files;mogrify