Class: Gloo::Verbs::Help
- Inherits:
-
Core::Verb
- Object
- Core::Baseo
- Core::Verb
- Gloo::Verbs::Help
- Defined in:
- lib/gloo/verbs/help.rb
Constant Summary collapse
- KEYWORD =
'help'.freeze
- KEYWORD_SHORT =
'?'.freeze
- BANNER =
"Entering the gloo help shell. Type 'quit' to exit.\n" \ "Try: verbs, objects, settings, extensions, libraries, docs, " \ "verb {name}, object {name}, doc {name}, library {name}, extension {name}\n".freeze
Constants inherited from Core::Baseo
Core::Baseo::NOT_IMPLEMENTED_ERR
Instance Attribute Summary
Attributes inherited from Core::Verb
Attributes inherited from Core::Baseo
Class Method Summary collapse
-
.doc_data ⇒ Object
Get the verb's documentation data.
-
.keyword ⇒ Object
Get the Verb's keyword.
-
.keyword_shortcut ⇒ Object
Get the Verb's keyword shortcut.
Instance Method Summary collapse
-
#run ⇒ Object
Run the verb.
Methods inherited from Core::Verb
#display_value, help, inherited, #initialize, #type_display
Methods inherited from Core::Baseo
Constructor Details
This class inherits a constructor from Gloo::Core::Verb
Class Method Details
.doc_data ⇒ Object
Get the verb's documentation data.
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 |
# File 'lib/gloo/verbs/help.rb', line 48 def self.doc_data { :name => KEYWORD, :shortcut => KEYWORD_SHORT, :description => 'Enter the interactive help shell. From there, ' \ 'look up verbs, object types, settings, extensions, libraries, ' \ 'and narrative doc pages, or get detailed help for a specific ' \ 'verb, object, doc page, loaded library, or loaded extension.', :syntax => [ 'help' ], :result => "Enters the help shell, prompt \"help> \". Commands: " \ 'verbs, objects, settings, extensions, libraries, docs (lists), ' \ 'verb {name}, object {name}, doc {name}, library {name}, ' \ 'extension {name} (detail for one, tab-completable — library ' \ '{name} / extension {name} show the README for a loaded core ' \ "library / user extension). Type 'quit' to leave the shell.", :examples => <<~EXAMPLES.strip > help help> verbs help> verb put help> object container help> docs help> doc getting_started help> library db help> extension alert help> quit EXAMPLES } end |
.keyword ⇒ Object
Get the Verb's keyword.
30 31 32 |
# File 'lib/gloo/verbs/help.rb', line 30 def self.keyword return KEYWORD end |
.keyword_shortcut ⇒ Object
Get the Verb's keyword shortcut.
37 38 39 |
# File 'lib/gloo/verbs/help.rb', line 37 def self.keyword_shortcut return KEYWORD_SHORT end |
Instance Method Details
#run ⇒ Object
Run the verb. Takes no arguments - always enters the interactive help shell.
22 23 24 25 |
# File 'lib/gloo/verbs/help.rb', line 22 def run @engine.log.show BANNER build_shell.start end |