File tree 1 file changed +7
-4
lines changed
1 file changed +7
-4
lines changed Original file line number Diff line number Diff line change @@ -1893,7 +1893,7 @@ class Options
1893
1893
}
1894
1894
1895
1895
std::string
1896
- help (const std::vector<std::string>& groups = {}) const ;
1896
+ help (const std::vector<std::string>& groups = {}, bool print_usage= true ) const ;
1897
1897
1898
1898
std::vector<std::string>
1899
1899
groups () const ;
@@ -2725,10 +2725,13 @@ Options::generate_all_groups_help(String& result) const
2725
2725
2726
2726
inline
2727
2727
std::string
2728
- Options::help (const std::vector<std::string>& help_groups) const
2728
+ Options::help (const std::vector<std::string>& help_groups, bool print_usage ) const
2729
2729
{
2730
- String result = m_help_string + " \n Usage:\n " +
2731
- toLocalString (m_program) + " " + toLocalString (m_custom_help);
2730
+ String result = m_help_string;
2731
+ if (print_usage)
2732
+ {
2733
+ result+= " \n Usage:\n " + toLocalString (m_program) + " " + toLocalString (m_custom_help);
2734
+ }
2732
2735
2733
2736
if (!m_positional.empty () && !m_positional_help.empty ()) {
2734
2737
result += " " + toLocalString (m_positional_help);
You can’t perform that action at this time.
0 commit comments