TwiceAsNice  2019-02-18
Functions
licsFmodhead.cc File Reference
#include <unistd.h>
#include <iostream>
#include <fitsio.h>
Include dependency graph for licsFmodhead.cc:

Functions

void usage (char *argv0)
 Print a usage syntax message detailing the command line. More...
 
int main (int argc, char **argv)
 licsFmodhead is a standalone program which edits FITS header data following directions from a configuration file. More...
 

Function Documentation

◆ main()

int main ( int  argc,
char **  argv 
)

licsFmodhead is a standalone program which edits FITS header data following directions from a configuration file.

The first command line argument is the path/file name of an existing FITS file which is to be modified.

The second argument and optionally further arguments are ASCII files structured very similar to the template files used with cfitsio and fmodhead.

Each of these may contain empty lines and comment lines (starting with #) that have no effect.

It may contain lines that start with at least 8 blanks. The rest of these lines is turned into COMMENT lines that are appended to the FITS header.

Finally, all other lines are interpreted as keyword-value-comment triples in FITS header style (with = and / as delimiters), that trigger adding that card to the header. (Existing keywords with the same name are removed).

Example file (see also the fmodhead examples in the source distribution:

# add a OBSERVAT keyword

OBSERVAT = "LBT" / on the mountain

# add a comment

Nice observation conditions. Dry with occasional snowflakes.

Parameters
[in]argcThe number of command line switches and arguments.
[in]argvThe vector of all command line arguments.
Returns
0 if the file manipulation was successful.
Since
2017-07-10
Author
R. J. Mathar

◆ usage()

void usage ( char *  argv0)

Print a usage syntax message detailing the command line.

Parameters
[in]argv0The name of the main program.
Since
2012-10-18