Sha256: fa21c51a160650a3659e52645f213d9f10bac983a2d9c677b6c5794f6f75818a
Contents?: true
Size: 689 Bytes
Versions: 34
Compression:
Stored size: 689 Bytes
Contents
module GLI module Commands module HelpModules class TerminalSynopsisFormatter def initialize(app,flags_and_switches) @app = app @basic_invocation = @app.exe_name.to_s @flags_and_switches = flags_and_switches end def synopses_for_command(command) synopses = FullSynopsisFormatter.new(@app,@flags_and_switches).synopses_for_command(command) if synopses.any? { |synopsis| synopsis.length > Terminal.instance.size[0] } CompactSynopsisFormatter.new(@app,@flags_and_switches).synopses_for_command(command) else synopses end end end end end end
Version data entries
34 entries across 34 versions & 1 rubygems