Module: ShellOpts::Grammar::WrappedNode
Instance Method Summary collapse
Instance Method Details
#lines(width, initial = 0) ⇒ Object
340 |
# File 'lib/shellopts/grammar.rb', line 340 def lines(width, initial = 0) @lines ||= words.wrap(width, initial) end |
#puts_descr ⇒ Object
184 185 186 187 |
# File 'lib/shellopts/formatter.rb', line 184 def puts_descr width = [Formatter.rest, Formatter::HELP_MAX_WIDTH].min puts lines(width) end |
#words ⇒ Object
339 |
# File 'lib/shellopts/grammar.rb', line 339 def words() @words ||= text.split(" ") end |