Class: Nesta::Commands::Edit
- Inherits:
-
Object
- Object
- Nesta::Commands::Edit
- Includes:
- Command
- Defined in:
- lib/nesta/commands.rb
Instance Method Summary collapse
- #execute ⇒ Object
-
#initialize(*args) ⇒ Edit
constructor
A new instance of Edit.
Methods included from Command
#copy_template, #copy_templates, #fail, #template_root, #update_config_yaml
Constructor Details
Instance Method Details
#execute ⇒ Object
60 61 62 63 64 65 66 |
# File 'lib/nesta/commands.rb', line 60 def execute editor = ENV.fetch('EDITOR') rescue IndexError $stderr.puts "No editor: set EDITOR environment variable" else system(editor, @filename) end |