Class: Runbook::Generators::DslExtension
- Inherits:
-
Thor::Group
- Object
- Thor::Group
- Runbook::Generators::DslExtension
show all
- Includes:
- Base
- Defined in:
- lib/runbook/generators/dsl_extension/dsl_extension.rb
Class Method Summary
collapse
Instance Method Summary
collapse
Methods included from Base
included, set_base_options
Class Method Details
.description ⇒ Object
7
8
9
|
# File 'lib/runbook/generators/dsl_extension/dsl_extension.rb', line 7
def self.description
"Generate a dsl_extension for adding custom runbook DSL functionality"
end
|
.long_description ⇒ Object
11
12
13
14
15
16
17
|
# File 'lib/runbook/generators/dsl_extension/dsl_extension.rb', line 11
def self.long_description
<<-LONG_DESC
This generator provides a template for extending Runbook's DSL. Using a
DSL extension, you can add custom commands to a book, section, or step
that can be used in your runbooks.
LONG_DESC
end
|
Instance Method Details
#create_dsl_extension ⇒ Object
21
22
23
24
25
26
27
|
# File 'lib/runbook/generators/dsl_extension/dsl_extension.rb', line 21
def create_dsl_extension
target = File.join(
parent_options[:root],
"#{name.underscore}.rb",
)
template('templates/dsl_extension.tt', target)
end
|