Exiftool and file-arrays

Started by mike1950r, January 19, 2022, 07:05:09 PM

Previous topic - Next topic

mike1950r

Hi,

we have problem with exiftool when we want to use file-arrays.

when we chain the files as
'file1 file2 file3 ...
making a variable for the chain,
we get problems when the amount of files becomes too long.

it works fine at when not too many files are in the chain.

so we need a possibility to use file-arrays:

"exiftool -UserComment= -overwrite_original -m FileArray"

Thanks for asistance for this.

Cheers mike

StarGeek

Can you clarify what you mean by "File Array"?

But if you're running into the character limit on the command line, you can save your list of files into a text file and call that list using the -@ (Argfile) option.
exiftool -@ /path/to/FileList.txt <more options>

You can even pipe the output of another command into exiftool using a dash to represent StdIn
find <conditions> | exiftool -@ - <more options>
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

mike1950r

Hi StarGeek,

thank you for yor answer.

An Array is a list of Filenames stored in an ArrayVariable. (such as $aFilePaths[10])
This comes from VBscript and also AutoIt Script language.

I can save the Array to file, I have tried this, but I could not get it working with exiftool.

So I will try:
exiftool -UserComment= -overwrite_original -m -@ /path/to/FileList.txt

Hope this is working.

cheers mike

mike1950r

Great,
working excellent.

Thanks very much StarGeek.

Cheers mike

StarGeek

Quote from: mike1950r on January 20, 2022, 06:42:41 AM
An Array is a list of Filenames stored in an ArrayVariable. (such as $aFilePaths[10])
This comes from VBscript and also AutoIt Script language.

That's what I thought it might be.  There is no way for exiftool to directly access a variable in a different programming language.
"It didn't work" isn't helpful. What was the exact command used and the output.
Read FAQ #3 and use that cmd
Please use the Code button for exiftool output

Please include your OS/Exiftool version/filetype

mike1950r

Ofcourse not.
8)

A normal variable has a max length.
An array variable exists multiple times as much as you declare.
So it's very usable.

But ofcourse exiftool cannot use other language variables.

The solution is to save this array in a file in separate lines.
And load it with -@

Everything is fine.

Thanks again.

Cheers mike