Last active
March 22, 2024 16:42
-
-
Save radavis/979ce4a34e84580be243 to your computer and use it in GitHub Desktop.
Using .railsrc and a Rails Template
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ~/.railsrc | |
--database=postgresql | |
--skip-bundle | |
--skip-spring | |
--skip-test-unit | |
--skip-turbolinks | |
--template=/path/to/rails_template.rb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# ~/rails_template.rb | |
gem_group :development, :test do | |
gem "capybara" | |
gem "factory_girl_rails" | |
gem "rspec-rails", "~> 3.0" | |
gem "pry-rails" | |
gem "shoulda-matchers" | |
end | |
gem_group :test do | |
gem "launchy", require: false | |
gem "valid_attribute" | |
end | |
gem_group :production, :staging do | |
gem "rails_12factor" | |
end | |
scss = <<-SCSS | |
@import "*"; | |
SCSS | |
run "echo '#{scss}' >> app/assets/stylesheets/application.scss" | |
run "rm app/assets/stylesheets/application.css" | |
run "rm README.rdoc" | |
run "echo '# #{@app_name.titleize}' >> README.md" | |
run("bundle install") | |
generate("rspec:install") | |
rake("db:create") | |
run "echo 'require \"capybara/rails\"' >> spec/rails_helper.rb" | |
git :init | |
git add: "." | |
git commit: "-a -m initial" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment