Niche Question - Anyone Start JEXIFToolGUI (Or Any Application) From A Bash Shell Script??

Started 9 months ago | Discussions
CharlesPhillips
CharlesPhillips Forum Member • Posts: 86
Niche Question - Anyone Start JEXIFToolGUI (Or Any Application) From A Bash Shell Script??

Ok this is a niche question.

I take photos of satellites (yes at night) and submit them to an astrometry site to "resolve" them. This allows me to use the photos to generate observations so a group can generate orbital information, etc.

A pal wrote a Bash shell script to take several photos (all in the same folder) and submit to the astrometry site and get the results back into a second folder. What a huge time saving!

I also use JEXIFToolGUI to get the actual precise time of the shutter and would like to have the script start up that "application" as well. This of course has proven to be a huge challenge. The script is in the Terminal but the application is in a package in the Applications folder.

Maybe someone here has done something like this?

One option is to have another installation of JEXIFToolGUI as a command line application...

-- hide signature --

Charles
Software Writer, Orbital Mechanics Guy, Amateur Astronomer

 CharlesPhillips's gear list:CharlesPhillips's gear list
Sony Cyber-shot DSC-H300 Nikon D200 +2 more
robgendreau Veteran Member • Posts: 8,216
Re: Niche Question - Anyone Start JEXIFToolGUI (Or Any Application) From A Bash Shell Script??

CharlesPhillips wrote:

Ok this is a niche question.

I take photos of satellites (yes at night) and submit them to an astrometry site to "resolve" them. This allows me to use the photos to generate observations so a group can generate orbital information, etc.

A pal wrote a Bash shell script to take several photos (all in the same folder) and submit to the astrometry site and get the results back into a second folder. What a huge time saving!

I also use JEXIFToolGUI to get the actual precise time of the shutter and would like to have the script start up that "application" as well. This of course has proven to be a huge challenge. The script is in the Terminal but the application is in a package in the Applications folder.

Maybe someone here has done something like this?

One option is to have another installation of JEXIFToolGUI as a command line application...

Wouldn't exiftool itself work? JExifToolGUI is just a gui for that program IIRC. So the command line tool IS exiftool. Or is having the gui the point? IIRC some cameras can report time in smaller increments than seconds, and exiftool can deal with that.

To use Terminal to open any application, use "open" https://osxdaily.com/2007/02/01/how-to-launch-gui-applications-from-the-terminal/

Barry Twycross Veteran Member • Posts: 4,010
Re: Niche Question - Anyone Start JEXIFToolGUI (Or Any Application) From A Bash Shell Script??

CharlesPhillips wrote:

Ok this is a niche question.

I take photos of satellites (yes at night) and submit them to an astrometry site to "resolve" them. This allows me to use the photos to generate observations so a group can generate orbital information, etc.

A pal wrote a Bash shell script to take several photos (all in the same folder) and submit to the astrometry site and get the results back into a second folder. What a huge time saving!

I also use JEXIFToolGUI to get the actual precise time of the shutter and would like to have the script start up that "application" as well. This of course has proven to be a huge challenge. The script is in the Terminal but the application is in a package in the Applications folder.

Maybe someone here has done something like this?

One option is to have another installation of JEXIFToolGUI as a command line application...

As suggested you probably want to use Exiftool directly on the command line, not a GUI wrapper around it.

For example:

exiftool -s /<file> -DateTimeOriginal -SubSecTime

Would get the ms timestamp out of a Panasonic file.

If you want to start an application, you need the "open" command. "man open" will tell you all you need to know about the open command, but as it says, "The open command opens a file (or a directory or URL), just as if you had double-clicked the file's icon." It's a very useful command to know.

You can open the data file, if it's got the right type so your application is the default application for it, or you can specify the application to use in a couple of ways, including by the app, or the bundle identifier. There are examples at the end of the man entry for that sort of thing.

 Barry Twycross's gear list:Barry Twycross's gear list
Panasonic GX850 Fujifilm GFX 50R Panasonic Lumix G Vario HD 12-32mm F3.5-5.6 Mega OIS Leica Nocticron 42.5mm Fujifilm GF 110mm F2 +9 more
CharlesPhillips
OP CharlesPhillips Forum Member • Posts: 86
Re: Niche Question - Anyone Start JEXIFToolGUI (Or Any Application) From A Bash Shell Script??
1

Wow! Two excellent and helpful replies!

I would prefer to open the GUI version since I feel more comfortable seeing the image, to double check my workflow. I only need the time of shutter (in this case, when it closes thanks to the Nikon D200 software) and exposure time (normally 15 or 20 seconds). I am gonna see if I can add this to the bash script and see if it works, then might drop back to just EXIFTool itself.

I often (well in the winter time) work with four images at the same time and need to make sure that I get the correct time with the correct image - the images go through several applications in a row.

I will give this a try an post back with results.

-- hide signature --

Charles
Software Writer, Orbital Mechanics Guy, Amateur Astronomer

 CharlesPhillips's gear list:CharlesPhillips's gear list
Sony Cyber-shot DSC-H300 Nikon D200 +2 more
robgendreau Veteran Member • Posts: 8,216
Re: Niche Question - Anyone Start JEXIFToolGUI (Or Any Application) From A Bash Shell Script??

CharlesPhillips wrote:

Wow! Two excellent and helpful replies!

I would prefer to open the GUI version since I feel more comfortable seeing the image, to double check my workflow. I only need the time of shutter (in this case, when it closes thanks to the Nikon D200 software) and exposure time (normally 15 or 20 seconds). I am gonna see if I can add this to the bash script and see if it works, then might drop back to just EXIFTool itself.

I often (well in the winter time) work with four images at the same time and need to make sure that I get the correct time with the correct image - the images go through several applications in a row.

I will give this a try an post back with results.

Might want to look at Graphic Converter as well. It does a great job of manipulating exif and IPTC info. Adobe Bridge too; it can filter by exposure time.

CharlesPhillips
OP CharlesPhillips Forum Member • Posts: 86
Re: Niche Question - Anyone Start JEXIFToolGUI (Or Any Application) From A Bash Shell Script??
1

Barry Twycross wrote:

CharlesPhillips wrote:

Ok this is a niche question.

I take photos of satellites (yes at night) and submit them to an astrometry site to "resolve" them. This allows me to use the photos to generate observations so a group can generate orbital information, etc.

A pal wrote a Bash shell script to take several photos (all in the same folder) and submit to the astrometry site and get the results back into a second folder. What a huge time saving!

I also use JEXIFToolGUI to get the actual precise time of the shutter and would like to have the script start up that "application" as well. This of course has proven to be a huge challenge. The script is in the Terminal but the application is in a package in the Applications folder.

Maybe someone here has done something like this?

One option is to have another installation of JEXIFToolGUI as a command line application...

As suggested you probably want to use Exiftool directly on the command line, not a GUI wrapper around it.

For example:

exiftool -s /<file> -DateTimeOriginal -SubSecTime

Would get the ms timestamp out of a Panasonic file.

If you want to start an application, you need the "open" command. "man open" will tell you all you need to know about the open command, but as it says, "The open command opens a file (or a directory or URL), just as if you had double-clicked the file's icon." It's a very useful command to know.

You can open the data file, if it's got the right type so your application is the default application for it, or you can specify the application to use in a couple of ways, including by the app, or the bundle identifier. There are examples at the end of the man entry for that sort of thing.

Another problem solved, the open command in the bash script works great. So the script submits 4 or so photos to a site that "resolves" them and then JEXIFToolGui starts so I can get the exposure time and duration. This will save a lot of time and avoid several potential mistakes.

Thanks again!

-- hide signature --

Charles
Software Writer, Orbital Mechanics Guy, Amateur Astronomer

 CharlesPhillips's gear list:CharlesPhillips's gear list
Sony Cyber-shot DSC-H300 Nikon D200 +2 more
Keyboard shortcuts:
FForum MMy threads