diff --git a/main.cpp b/main.cpp index ab10ba8..0d4a694 100644 --- a/main.cpp +++ b/main.cpp @@ -114,6 +114,7 @@ int main(int argc, char *argv[]) // Commandline options (no config file) options_cli_no_cfg.add_options() ("help,h", "Print help message") + ("version", "Print version information") ("login", bpo::value(&config.bLogin)->zero_tokens()->default_value(false), "Login") ("list", bpo::value(&config.bList)->zero_tokens()->default_value(false), "List games") ("list-details", bpo::value(&config.bListDetails)->zero_tokens()->default_value(false), "List games with detailed info") @@ -183,6 +184,12 @@ int main(int argc, char *argv[]) return 0; } + if (vm.count("version")) + { + std::cout << VERSION_STRING << std::endl; + return 0; + } + if (vm.count("chunk-size")) config.iChunkSize <<= 20; // Convert chunk size from bytes to megabytes