Class: Completely::Commands::Generate

Inherits:
Base
  • Object
show all
Defined in:
lib/completely/commands/generate.rb

Instance Method Summary collapse

Methods inherited from Base

environment_config_path, environment_debug, option_function, param_config_path

Instance Method Details

#runObject



26
27
28
29
30
31
32
# File 'lib/completely/commands/generate.rb', line 26

def run
  wrap = args['--wrap']
  output = wrap ? wrapper_function(wrap) : script
  File.write output_path, output
  say "Saved m`#{output_path}`"
  syntax_warning unless completions.valid?
end