Class: Spline::Command
- Inherits:
-
Thor::Group
- Object
- Thor::Group
- Spline::Command
show all
- Includes:
- Thor::Actions
- Defined in:
- lib/spline/commands/command.rb
Class Method Summary
collapse
Class Method Details
.alias ⇒ Object
18
19
20
|
# File 'lib/spline/commands/command.rb', line 18
def self.alias
command_name
end
|
.command_name ⇒ Object
name refers to the class name with module. Spline::Command in this case
14
15
16
|
# File 'lib/spline/commands/command.rb', line 14
def self.command_name
name.downcase[/\w+::(\w+)command/, 1]
end
|
.description ⇒ Object
26
27
28
|
# File 'lib/spline/commands/command.rb', line 26
def self.description
"#{command_name} description"
end
|
.source_root ⇒ Object
root of project, from where we reference the templates
9
10
11
|
# File 'lib/spline/commands/command.rb', line 9
def self.source_root
File.dirname(__FILE__) + "/.."
end
|
.usage ⇒ Object
22
23
24
|
# File 'lib/spline/commands/command.rb', line 22
def self.usage
command_name
end
|