Git Product home page Git Product logo

rails3-app's Introduction

Rails 3, RSpec, Fabrication or Factory Girl, Haml, and jQuery

Please note

Thomas Maas points out that the recent switch by github to only support https has exposed a bug in Rails (see https://rails.lighthouseapp.com/projects/8994/tickets/5926). In order to use these templates, you should clone the repo and refer to the templates from your local file system instead of their github uris as shown below.

Easily generate a Rails 3 application with RSpec, Factory Girl, Haml, and jQuery in one line:

% rails new my_app -J -T -m \
https://github.com/leshill/rails3-app/raw/master/app.rb

Need Cucumber?

Use this generator file instead:

% rails new my_app -J -T -m \
https://github.com/leshill/rails3-app/raw/master/cuke.rb

Want Fabrication instead of Factory Girl?

Use either of the following generators instead:

% rails new my_app -J -T -m \
http://github.com/leshill/rails3-app/raw/master/fabrication.rb

% rails new my_app -J -T -m \
http://github.com/leshill/rails3-app/raw/master/fabrication_cuke.rb

rvm

We love rvm, so the application has an .rvmrc generated to specify a gemset.

Generators

We use the Factory Girl and Haml Rails 3 generators β€” the generators for RSpec and Fabrication are packaged within their respective gems. The Factory Girl and Haml generators are from the haml-rails and factory_girl_generator gems.

JavaScript Includes

Since the Rails helper javascript_include_tag :defaults is looking for Prototype, we change the default JavaScript includes to be jQuery.

git

We love git, so the application has a git repo initialized with all the initial changes staged.

Wrap Up

After the application has been generated, there are a few final command to finish the install, check the output!

Note on Patches/Pull Requests

  • Fork the project.
  • Make your feature addition or bug fix.
  • Add tests for it. This is important so I don’t break it in a future version unintentionally.
  • Commit, do not mess with rakefile, version, or history. (if you want to have your own version, that is fine but bump version in a commit by itself I can ignore when I pull)
  • Send me a pull request. Bonus points for topic branches.

rails3-app's People

Contributors

leshill avatar thomasmaas avatar elizabrock avatar

Stargazers

Gun.io Robot avatar

Watchers

Gun.io Robot avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.