-
-
Save rrooding/2918035 to your computer and use it in GitHub Desktop.
Rails Backbone 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
gem_group :assets do | |
gem 'haml_coffee_assets' | |
end | |
gem_group :assets, :development do | |
gem 'rails-backbone' | |
end | |
gem 'haml-rails' | |
gem 'draper' | |
gem_group :test, :development do | |
gem 'konacha' | |
gem 'capybara-webkit' | |
gem 'rspec-rails' | |
end | |
run 'bundle' | |
generate 'backbone:install' | |
generate 'rspec:install' | |
file 'app/decorators/application_decorator.rb' do | |
<<-CODE.gsub(/^ {4}/, '') | |
class ApplicationDecorator < Draper::Base | |
# your methods go here | |
end | |
CODE | |
end | |
initializer 'konacha.rb' do | |
<<-INITIALIZER.gsub(/^ {4}/, '') | |
if defined?(Konacha) | |
Konacha.configure do |config| | |
config.spec_dir = 'spec/javascripts' | |
config.driver = :webkit | |
end | |
end | |
INITIALIZER | |
end | |
rake 'db:create:all' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment