Created
August 14, 2010 18:16
-
-
Save defeated/524546 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
# create fresh git repo | |
git :init | |
git :add => '.' | |
git :commit => '-a -m "fresh rails app"' | |
# include gems | |
gem 'rspec', '>= 2.0.0.beta.19', :group => :test | |
gem 'rspec-rails', '>= 2.0.0.beta.19', :group => :test | |
gem 'cucumber', '>= 0.8.5', :group => :test | |
gem 'cucumber-rails', '>= 0.3.2', :group => :test | |
gem 'webrat', :group => :test | |
# run cucumber and rspec generators | |
generate 'rspec:install' | |
generate 'cucumber:install --rspec --webrat' | |
# create rspec.rb in the config/initializers directory to use rspec as the default test framework | |
initializer 'rspec.rb', <<-EOF | |
Rails.application.config.generators.test_framework :rspec | |
EOF | |
# download latest unobtrusive rails adapter for jquery | |
get 'http://github.com/rails/jquery-ujs/raw/master/src/rails.js', 'public/javascripts/rails.js' | |
# create jquery.rb in the config/initializers directory to use jquery as the default javascript framework | |
initializer 'jquery.rb', <<-EOF | |
Rails.application.config.action_view.javascript_expansions[:defaults] = %w(http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js rails) | |
EOF | |
# commit template results to repo | |
git :commit => '-a -m "applied application template"' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Check out http://refactored.tumblr.com/post/953522976/rails-3-getting-started-part-3-application-templates for how this is used.