Skip to content

Instantly share code, notes, and snippets.

@rupert-madden-abbott
Created October 19, 2011 00:17
Show Gist options
  • Save rupert-madden-abbott/1297141 to your computer and use it in GitHub Desktop.
Save rupert-madden-abbott/1297141 to your computer and use it in GitHub Desktop.
Rails App Template
system "rm -rf /tmp/app"
git clone: "git://gist.github.com/1296514.git /tmp/app"
# Rails Generators
application do
<<-EOS
config.generators do |g|
g.template_engine :haml
g.test_framework :rspec, fixture: true, views: false
g.integration_tool :rspec, fixture: true, views: true
g.fixture_replacement :factory_girl, dir: "spec/factories"
g.form_builder :simple_form
end
EOS
end
# Sorcery
if yes? "Would you like to install Sorcery?"
generate "controller User index show new edit create update destroy"
generate "sorcery:install user_activation remember_me reset_password brute_force_protection activity_logging external"
say "Sorcery and it's submodules will now need to be configured: https://github.com/NoamB/sorcery/wiki"
elsif
generate "scaffold User"
end
generate "cancan:ability" # CanCan
generate "simple_form:install" # Simple Form
generate "client_side_validations:install" # Client Side Validations
generate "rspec:install" # RSpec
generate "cucumber:install" # Cucumber
system "guard init && guard init bundler && guard init passenger && guard init livereload && guard init rspec && guard init cucumber && guard init annotate && guard init rails_best_practices"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment