Sha256: 472ca85dfd8fd5052e6f66280300c006b80aec6f3e4c0681e7195102a82bed67

Contents?: true

Size: 1.23 KB

Versions: 7

Compression:

Stored size: 1.23 KB

Contents

<%=
  if !program(:nobanner)
    begin
      require 'openflight/banner'
      OpenFlight::Banner.render(title: program(:application), version: program(:version))
    rescue LoadError
      nil
    end
  end
-%>
  <%= $terminal.color "NAME", :bold %>:

    <%= program :name %>

  <%= $terminal.color "DESCRIPTION", :bold %>:

    <%= Commander::HelpFormatter.indent 4, program(:description) %>

  <%= $terminal.color "COMMANDS", :bold %>:
<% for name, command in @help_commands.sort -%>
	<% unless alias? name %>
    <%= "%-#{max_command_length}s %s" % [command.name, command.summary || command.description] -%>
	<% end -%>
<% end %>
<% unless @aliases.empty? %>
  <%= $terminal.color "ALIASES", :bold %>:
  <% for alias_name, args in @aliases.sort %>
    <%= "%-#{max_aliases_length}s %s %s" % [alias_name, command(alias_name).name, args.join(' ')] -%>
  <% end %>
<% end %>
<% unless @help_options.empty? -%>
  <%= $terminal.color "GLOBAL OPTIONS", :bold %>:
	<% for option in @help_options -%>

    <%= option[:switches].join ', ' %> 
        <%= option[:description] %>
	<% end -%>
<% end -%>
<% if program :help -%>
  <% for title, body in program(:help) %>
  <%= $terminal.color title.to_s.upcase, :bold %>:

    <%= body %>
  <% end -%>
<% end -%>

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
commander-openflighthpc-2.0.2 lib/commander/help_formatters/terminal/help.erb
commander-openflighthpc-2.0.1 lib/commander/help_formatters/terminal/help.erb
commander-openflighthpc-2.0.0 lib/commander/help_formatters/terminal/help.erb
commander-openflighthpc-1.2.0 lib/commander/help_formatters/terminal/help.erb
commander-openflighthpc-1.1.2 lib/commander/help_formatters/terminal/help.erb
commander-openflighthpc-1.1.1 lib/commander/help_formatters/terminal/help.erb
commander-openflighthpc-1.1.0 lib/commander/help_formatters/terminal/help.erb