ExifTool Forum

ExifTool => Newbies => Topic started by: j99mac on November 24, 2021, 06:40:12 AM

Title: Mske folder based on part of filename
Post by: j99mac on November 24, 2021, 06:40:12 AM
Is it possible to make a new folder based on first part of filename then move files in to it with the same name? Then rename the file 1,2,3?

Example
abc_001.tif move to new folder abc
Then rename file 001.tif
Title: Re: Mske folder based on part of filename
Post by: Phil Harvey on November 24, 2021, 07:48:31 AM
exiftool "-filename=%3f/%.4f.%e" DIR

This syntax is explained, with examples, in the -w section of the application documentation.

- Phil
Title: Re: Mske folder based on part of filename
Post by: j99mac on November 24, 2021, 08:00:20 AM
Can exiftool make a dir based on part if a file name example abc_123 and the new dir is abc. Would this work if i have multiple file with different names. Then move file to the new folder based in the filename
Title: Re: Mske folder based on part of filename
Post by: Phil Harvey on November 24, 2021, 04:01:17 PM
Yes, my command does that.

Read here (https://exiftool.org/filename.html) for more information about moving/renaming files.

- Phil