Skip to content

Commit

Permalink
improved help message
Browse files Browse the repository at this point in the history
  • Loading branch information
FRex committed Mar 31, 2022
1 parent cf1c1d5 commit de9fcae
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions analyzepng.c
Original file line number Diff line number Diff line change
Expand Up @@ -183,11 +183,19 @@ static int print_usage(const char * argv0, FILE * f)
{
argv0 = filepath_to_filename(argv0);
fprintf(f, "%s - print information about chunks of given png files\n", argv0);
if(BLA_WMAIN_USING_WMAIN_BOOLEAN)
fprintf(f, "https://github.com/FRex/analyzepng\n");

#ifdef GIT_COMMIT_HASH
fprintf(f, "built from commit %s\n", GIT_COMMIT_HASH);
#endif

#if BLA_WMAIN_USING_WMAIN_BOOLEAN == 1
fprintf(f, "Windows build capable of colors and UTF-16 filenames\n");
#endif

if(OPENBSD_PLEDGE_AND_UNVEIL_USED)
#if OPENBSD_PLEDGE_AND_UNVEIL_USED == 1
fprintf(f, "OpenBSD build using pledge(2) and unveil(2) for extra safety\n");
#endif

fprintf(f, "Usage: %s [--no-idat] file.png... # a single - means read from stdin\n", argv0);
fprintf(f, " --h OR --help #print this help to stdout\n");
Expand Down

0 comments on commit de9fcae

Please sign in to comment.