Class: Stevenson::Application
- Inherits:
-
Thor
- Object
- Thor
- Stevenson::Application
- Defined in:
- lib/stevenson/application.rb
Instance Method Summary collapse
Instance Method Details
#generate_dotfile ⇒ Object
63 64 65 66 |
# File 'lib/stevenson/application.rb', line 63 def generate_dotfile Dotfile.install puts "Generated dotfile at #{Dotfile.path}" end |
#new(output_directory, config_path) ⇒ Object
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
# File 'lib/stevenson/application.rb', line 42 def new(output_directory, config_path) # Load the template using the template loader template = Stevenson::Template.load([:template], ) # Place yml files template.place_config(config_path) template.place_files([:data], '_data') if [:data] # Run output filters, in order, against the template directory = Stevenson::OutputFilter.generate!(template, ) # Run deployers against filtered template directory Stevenson::Deployer.deploy(directory, ) rescue StandardError => e say e. ensure template.close end |