Class: Terraspace::CLI::New::Plugin::Core

Inherits:
Sequence
  • Object
show all
Includes:
Helper
Defined in:
lib/terraspace/cli/new/plugin/core.rb

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Sequence

base_options, component_options

Methods included from Util::Logging

#logger

Class Method Details

.optionsObject



7
8
9
10
11
# File 'lib/terraspace/cli/new/plugin/core.rb', line 7

def self.options
  [
    [:force, aliases: %w[y], type: :boolean, desc: "Bypass overwrite are you sure prompt for existing files"],
  ]
end

Instance Method Details

#create_pluginObject



14
15
16
17
18
# File 'lib/terraspace/cli/new/plugin/core.rb', line 14

def create_plugin
  puts "=> Creating new plugin: #{name}"
  core_template_source("plugin/core")
  directory ".", "terraspace_plugin_#{name}"
end