Advertisement
mine260309

Untitled

Oct 10th, 2019
127
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.47 KB | None | 0 0
  1. #include <cstdio>
  2. #include <string>
  3.  
  4. #ifdef CLI11
  5. #include <CLI/CLI.hpp>
  6. #endif
  7.  
  8. int main(int argc, char** argv)
  9. {
  10.     std::string psuPath;
  11. #ifdef CLI11
  12.     CLI::App app{"PSU utils app for OpenBMC"};
  13.     app.add_option("-g,--getversion", psuPath,
  14.                    "Get PSU version from inventory path")
  15.         ->required();
  16.     CLI11_PARSE(app, argc, argv);
  17. #else
  18.     (void)argc;
  19.     (void)argv;
  20. #endif
  21.     printf("%s\n", psuPath.c_str());
  22.     return 0;
  23. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement