Suspenders

This is Philosophie's fork of Suspenders, a Rails application template originally created by thoughtbot. This repo has strayed significantly from thoughtbot's and is not intended to go back upstream.

Installation

First install the gem:

gem install philosophies-suspenders

Or update if you already have the gem installed:

gem update philosophies-suspenders

Then run:

philosophies-suspenders projectname

This will create a Rails app in projectname using the latest version of Rails.

Gemfile

To see the latest and greatest gems, look at Suspenders' Gemfile, which will be appended to the default generated projectname/Gemfile. After the first bundle install, Suspenders will apply pessimistic version-locking on the Gemfile to only allow patch-level updates.

It includes application gems like:

And development gems like:

And testing gems like:

Other goodies

Suspenders also comes with:

Webpack(er)

Optionally use Webpacker instead of (or in addition to) asset pipeline:

philosophies-suspenders my_new_app --webpack

CSS Frameworks

You can optionally install a CSS Framework options: bourbon_n_friends, bootstrap, foundation

philosophies-suspenders my_new_app --css-framework=CSS_FRAMEWORK

Heroku

By default, suspenders will:

Please ensure your Heroku account has a verified credit card in order for the above addons to be installed.

You can optionally specify alternate Heroku flags:

philosophies-suspenders app \
  --heroku-flags "--region eu --addons newrelic,pgbackups,ssl"

See all possible Heroku flags:

heroku help create

You can bypass all Heroku functionality with the --skip-heroku option:

philosophies-suspenders app --skip-heroku true

Git

By default, suspenders will:

By default, pre-commit hooks are setup to run bin/rails. To override this while committing pass the --no-verify option to your commit.

You can optionally provide a remote URL via the --origin option and suspenders will push all branches to that remote.

philosophies-suspenders app --origin git@github.com:philosopie/app.git

You can bypass all git functionality with the --skip-git option:

philosophies-suspenders app --skip-git true

GitHub

You can optionally create a GitHub repository for the suspended Rails app. It requires that you have Hub on your system:

curl http://hub.github.com/standalone -sLo ~/bin/hub && chmod +x ~/bin/hub
philosophies-suspenders app --github organization/project

This has the same effect as running:

hub create organization/project

Spring

Suspenders uses spring by default. It makes Rails applications load faster, but it might introduce confusing issues around stale code not being refreshed. If you think your application is running old code, run spring stop. And if you'd rather not use spring, add DISABLE_SPRING=1 to your login file.

Dependencies

Suspenders requires the latest version of Ruby.

Some gems included in Suspenders have native extensions. You should have GCC installed on your machine before generating an app with Suspenders.

Use OS X GCC Installer for Snow Leopard (OS X 10.6).

Use Command Line Tools for XCode for Lion (OS X 10.7) or Mountain Lion (OS X 10.8).

We use Capybara Webkit for full-stack JavaScript integration testing. It requires QT. Instructions for installing QT are here.

PostgreSQL needs to be installed and running for the db:create rake task.

Contributing / Feature requests

Philosophie's Suspenders is meant to support the core functionality of a new rails project. Many nice to have features are therefore not appropriate. If you have an idea for a new feature, here are the steps for having it added:

Deploy new version to rubygems

Update to newest ruby and rails versions

License

Suspenders is Copyright © 2008-2015 thoughtbot. It is free software, and may be redistributed under the terms specified in the LICENSE file.