Class: Uniword::Plugin::CliCommand
- Inherits:
-
Object
- Object
- Uniword::Plugin::CliCommand
- Defined in:
- lib/uniword/plugin/cli_command.rb
Overview
Base class for plugin-provided CLI commands. A plugin CLI command is a Thor subclass that the main CLI registers as a subcommand.
Subclasses declare subcommand_name (the name CLI users type)
and description (shown in uniword help).
Class Method Summary collapse
-
.description ⇒ String
One-line description.
-
.subcommand_name ⇒ Symbol
Subcommand name (e.g. :myplugin).
-
.thor_class ⇒ Class<Thor>
The Thor subclass to register.
Class Method Details
.description ⇒ String
Returns one-line description.
19 20 21 |
# File 'lib/uniword/plugin/cli_command.rb', line 19 def description raise NotImplementedError end |
.subcommand_name ⇒ Symbol
Returns subcommand name (e.g. :myplugin).
14 15 16 |
# File 'lib/uniword/plugin/cli_command.rb', line 14 def subcommand_name raise NotImplementedError end |
.thor_class ⇒ Class<Thor>
Returns the Thor subclass to register.
24 25 26 |
# File 'lib/uniword/plugin/cli_command.rb', line 24 def thor_class raise NotImplementedError end |