Find all files with no EXIF data?

Started by nogginthenog, May 22, 2015, 02:12:55 PM

Previous topic - Next topic

nogginthenog

Would some kind soul help a person who, although having many years' experience of command-line applications, is new to ExifTool and a bit pressed for time. I need to do a recursive directory scan and output the filenames (preferably with full path) of all files that have no EXIF info at all, while remaining silent on all files that do have EXIF info. 

I'm sure this is a piece of cake to you lot.

Phil Harvey

If you really do mean EXIF, then yes, it is a piece of cake:

exiftool -p "$directory/$filename" -if "not $exif:all" -r DIR

(there are lots of different ways to format the output, but I have given you just the full path name of the file here)

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

nogginthenog

Superb. Many thanks! I shall study that example till I have a proper grasp. Meanwhile, may I ask why you wondered whether I really did mean EXIF info?  What am I missing?

Phil Harvey

Because ExifTool also extracts other information types like XMP for example.  Many people new to metadata don't know the difference.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

nogginthenog


Phil Harvey

Neat!  I just discovered an ExifTool feature that I had forgotten (some of those Extra tags are really cool):

You can use the FilePath tag to return the absolute file path if you want...

exiftool -s3 -q -filepath -if "not $exif:all" -r DIR

This saves having to use the -p option, but then we need to add -s3 -q to return only tag values and suppress other output.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

humbledumble

Firstly - thanks for the excellent tool. Helped me enourmosly.
I just looked up this specific issue, but low coffeeine-levels managed to make me type DIR and I had the first laugh of the day:
;D


Error: File not found - DIR
You were meant to enter any valid directory name, not "DIR" literally.


PS: Sorry for the necro-bump.

Phil Harvey

...where DIR is the name of a directory/folder containing the images.  On Mac/Linux/PowerShell, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).