parent
01798ee7a0
commit
2abdd4af4d
@ -1893,7 +1893,7 @@ class Options
|
|||||||
}
|
}
|
||||||
|
|
||||||
std::string
|
std::string
|
||||||
help(const std::vector<std::string>& groups = {}) const;
|
help(const std::vector<std::string>& groups = {}, bool print_usage=true) const;
|
||||||
|
|
||||||
std::vector<std::string>
|
std::vector<std::string>
|
||||||
groups() const;
|
groups() const;
|
||||||
@ -2725,10 +2725,13 @@ Options::generate_all_groups_help(String& result) const
|
|||||||
|
|
||||||
inline
|
inline
|
||||||
std::string
|
std::string
|
||||||
Options::help(const std::vector<std::string>& help_groups) const
|
Options::help(const std::vector<std::string>& help_groups, bool print_usage) const
|
||||||
{
|
{
|
||||||
String result = m_help_string + "\nUsage:\n " +
|
String result = m_help_string;
|
||||||
toLocalString(m_program) + " " + toLocalString(m_custom_help);
|
if(print_usage)
|
||||||
|
{
|
||||||
|
result+= "\nUsage:\n " + toLocalString(m_program) + " " + toLocalString(m_custom_help);
|
||||||
|
}
|
||||||
|
|
||||||
if (!m_positional.empty() && !m_positional_help.empty()) {
|
if (!m_positional.empty() && !m_positional_help.empty()) {
|
||||||
result += " " + toLocalString(m_positional_help);
|
result += " " + toLocalString(m_positional_help);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user