Class: Baldwin::Installer
- Inherits:
-
Thor::Group
- Object
- Thor::Group
- Baldwin::Installer
- Includes:
- Thor::Actions
- Defined in:
- lib/baldwin/installer.rb
Class Method Summary collapse
Instance Method Summary collapse
- #add_baldwin_setup_to_spec_helper ⇒ Object
- #copy_example_rails_template ⇒ Object
- #create_appraisals_file ⇒ Object
- #ignore_dummy_rails_apps ⇒ Object
Class Method Details
.source_root ⇒ Object
34 35 36 |
# File 'lib/baldwin/installer.rb', line 34 def self.source_root File.dirname __FILE__ end |
Instance Method Details
#add_baldwin_setup_to_spec_helper ⇒ Object
23 24 25 26 27 28 |
# File 'lib/baldwin/installer.rb', line 23 def add_baldwin_setup_to_spec_helper create_file 'spec/spec_helper.rb', <<-EOS require 'baldwin/setup' require 'rspec/rails' EOS end |
#copy_example_rails_template ⇒ Object
30 31 32 |
# File 'lib/baldwin/installer.rb', line 30 def copy_example_rails_template copy_file 'rails_template.rb', 'spec/rails/rails_template.rb' end |
#create_appraisals_file ⇒ Object
13 14 15 16 17 18 19 20 21 |
# File 'lib/baldwin/installer.rb', line 13 def create_appraisals_file create_file 'Appraisals', <<-EOS # add your rails configurations to test against here, like: appraise 'rails-3.1.0' do gem 'rails', '3.1.0' end # see https://github.com/thoughtbot/appraisal for more info EOS end |
#ignore_dummy_rails_apps ⇒ Object
7 8 9 10 11 |
# File 'lib/baldwin/installer.rb', line 7 def ignore_dummy_rails_apps append_to_file '.gitignore', <<-EOS spec/rails/rails-* EOS end |