Skip to content
This repository has been archived by the owner on May 21, 2024. It is now read-only.

Commit

Permalink
Merge pull request #1760 from mike-sul/fix/aktualizr-get/check-params
Browse files Browse the repository at this point in the history
aktualizr-get: fix the issue with param check
  • Loading branch information
pattivacek authored Sep 18, 2020
2 parents 2b095ff + c841de1 commit 5336fd2
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/aktualizr_get/main.cc
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
namespace bpo = boost::program_options;

void check_info_options(const bpo::options_description &description, const bpo::variables_map &vm) {
if (vm.count("help") != 0 || (vm.count("command") == 0 && vm.count("version") == 0)) {
if (vm.count("help") != 0 || (vm.count("url") == 0 && vm.count("version") == 0)) {
std::cout << description << '\n';
exit(EXIT_SUCCESS);
}
Expand All @@ -31,9 +31,9 @@ bpo::variables_map parse_options(int argc, char **argv) {
description.add_options()
("help,h", "print usage")
("version,v", "Current aktualizr-get version")
("config,c", bpo::value<std::vector<boost::filesystem::path> >()->composing(), "configuration file or directory")
("config,c", bpo::value<std::vector<boost::filesystem::path> >()->composing(), "configuration file or directory, by default /var/sota")
("loglevel", bpo::value<int>(), "set log level 0-5 (trace, debug, info, warning, error, fatal)")
("url,u", bpo::value<std::string>(), "url to get");
("url,u", bpo::value<std::string>(), "url to get, mandatory");
// clang-format on

bpo::variables_map vm;
Expand Down

0 comments on commit 5336fd2

Please sign in to comment.