How do you move a file with a specific tag

Started by yaron, July 29, 2012, 03:53:57 AM

Previous topic - Next topic

yaron

i'm trying to move files that have a specific tag(keywords) to another folder,
What I managed to do is

exiftool "-directory<keywords" *.jpg

But it created a folder with the folders named according to keywords,
And it's not exactly what I'm trying to do.

I want to move the file if it has something in the keywords tag
Maybe someone knows how it's done right?

yaron

something that works
that I composed from a few different posts on the forum

exiftool -directory=test -if "not defined $keywords" -ext eps .

posted it back
Maybe this will help Someone

Phil Harvey

The command you posted will move files with no keywords.

To move files with a specific keyword, you can use -if "$keywords =~ /some keyword/i"

(the i makes it a case-insensitive match.  Use single quotes on Mac/Linux, or double quotes as above in Windows)

- 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 ($).