ExifTool Forum

ExifTool => Newbies => Topic started by: Moonbase59 on April 12, 2022, 08:53:33 AM

Title: Where are the sample *.fmt files stored (on Linux)?
Post by: Moonbase59 on April 12, 2022, 08:53:33 AM
I'd like to play around with the (assumingly) provided sample print format files before creating my own (to create GPX track files from images/videos).

Now for the life of me I can't find where these are stored on my a) Manjaro Linux and b) Linux Mint systems.

One example (https://exiftool.org/exiftool_pod.html#GEOTAGGING-EXAMPLES) shows just to use "-p gpx.fmt"
exiftool -p gpx.fmt -d %Y-%m-%dT%H:%M:%SZ dir > out.gpx
but this doesn't work—apparently exiftool (12.41) doesn't automatically look them up (except in the current folder).

So my questions are:

Thanks for your help!

N.B.: I installed exiftool 12.41 on both Manjaro and Linux Mint using the procedure from the docs (https://exiftool.org/install.html#Unix).
Title: Re: Where are the sample *.fmt files stored (on Linux)?
Post by: StarGeek on April 12, 2022, 10:17:07 AM
Quote from: Moonbase59 on April 12, 2022, 08:53:33 AM
Now for the life of me I can't find where these are stored on my a) Manjaro Linux and b) Linux Mint systems.

If you downloaded the full Perl archive from the main page, they would be in the fmt_files directory.  You can also download them from Github (https://github.com/exiftool/exiftool/tree/master/fmt_files) as well as the included arg_files and config_files. See here (https://github.com/exiftool/exiftool).

QuoteIs there a cross-platform portable way to access these, say for the command above? Maybe by using kind of a folder variable that points to where they are stored?

Not for the FMT files. They have to either be in the current directory or you have to give the full path to the file.

Exiftool will be able to read config and args files that are in the main exiftool application directory without having to specify the full path.
Title: Re: Where are the sample *.fmt files stored (on Linux)?
Post by: Moonbase59 on April 12, 2022, 11:20:09 AM
Ah, I see.  They're actually in the extracted downloads folder. Apparently some misunderstanding on my side. I assumed they would be installed in some system location (like exiftool gets installed into /usr/local/bin, and the man pages installed).

So you're basically saying the *.fmt files are just in my extracted folder from the downloaded archive and not installed somewhere? (The download I would usually delete after installing but kept just because I wasn't finished yet.)

It'd be nice to see the *.fmt files—in a future version—in something like "$HOME/.config/exiftool/" or the like, I should think.
Title: Re: Where are the sample *.fmt files stored (on Linux)?
Post by: Phil Harvey on April 12, 2022, 09:54:58 PM
The included .fmt and .config files are just samples of things some people have found useful.  I don't think it makes sense to install them for everyone.

- Phil
Title: Re: Where are the sample *.fmt files stored (on Linux)?
Post by: Moonbase59 on April 13, 2022, 06:27:59 AM
Hm, ok. Since a workflow typical for many users is "hopping around", i.e. copying files into folders from the camera(s) and working on them prior to using heftier software like Darktable, Lightroom or a video editor, usually by quickly opening a terminal prompt in folders to use things like exiftool and supporting scripts, I'm tempted to use something like $(xdg-user-dir TEMPLATES)/exiftool for the *.fmt files.

Any fellow Linux users got a better idea?
And do MacOS and the WSL (Windows Subsystem for Linux) have xdg-user-dir?

Rationale: For recurring work, one would not want to keep processing files around in lots of folders. The system's user Templates folder seems a good place for that.
Title: Re: Where are the sample *.fmt files stored (on Linux)?
Post by: Phil Harvey on April 13, 2022, 06:54:25 AM
I'm on MacOS and I've never heard of xdg-user-dir.

- Phil