diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/DabMod.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/DabMod.cpp b/src/DabMod.cpp index 63a1e98..979df87 100644 --- a/src/DabMod.cpp +++ b/src/DabMod.cpp @@ -647,6 +647,18 @@ int main(int argc, char* argv[]) setenv("TZ", "", 1); tzset(); + // Version handling is done very early to ensure nothing else but the version gets printed out + if (argc == 2 and strcmp(argv[1], "--version") == 0) { + fprintf(stdout, "%s\n", +#if defined(GITVERSION) + GITVERSION +#else + PACKAGE_VERSION +#endif + ); + return 0; + } + try { return launch_modulator(argc, argv); } |