Skip to content

Instantly share code, notes, and snippets.

@drd
Created March 9, 2009 23:29
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save drd/76551 to your computer and use it in GitHub Desktop.
Save drd/76551 to your computer and use it in GitHub Desktop.
#Install gems
gem 'mocha'
gem 'thoughtbot-shoulda'
gem 'thoughtbot-factory_girl'
gem 'technicalpickles-shoulda_generator'
gem 'mislav-will_paginate', :version => '~> 2.2.3', :lib => 'will_paginate', :source => 'http://gems.github.com'
gem 'haml'
#install plugins
file 'vendor/plugins/haml/init.rb', <<-END
require 'rubygems'
begin
require File.join(File.dirname(__FILE__), 'lib', 'haml') # From here
rescue LoadError
require 'haml' # From gem
end
# Load Haml and Sass
Haml.init_rails(binding)
END
#Configure Application Controller
gsub_file 'app/controllers/application_controller.rb', /#\s*(filter_parameter_logging :password)/, '\1'
#Delete all unecessary files
run "rm README"
run "rm public/index.html"
run "rm public/favicon.ico"
run "rm public/robots.txt"
#Setup git ignore file
file '.gitignore', <<-END
config/database.yml
db/schema.rb
log/*.log
public/stylesheets/*.css
tmp/
END
run 'touch tmp/.gitignore log/.gitignore'
#add to git
git :init
git :add => '.'
git :commit => "-a -m 'Initial commit'"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment