Permalink
Browse files

the README that gets generated with the app should be awesome, not te…

…rrible.
  • Loading branch information...
croaky committed Dec 4, 2011
1 parent 257ea39 commit c5ba37098a424ca189b8597904dbdd3cdd756f43
Showing with 78 additions and 72 deletions.
  1. +1 −2 lib/suspenders/app_builder.rb
  2. +77 −0 templates/README.md
  3. +0 −70 templates/README_FOR_SUSPENDERS
@@ -3,7 +3,7 @@ class AppBuilder < Rails::AppBuilder
include Suspenders::Actions
def readme
- copy_file "README_FOR_SUSPENDERS"
+ copy_file "README.md"
end
def remove_public_index
@@ -175,7 +175,6 @@ def setup_default_rake_task
append_file "Rakefile" do
"task(:default).clear\ntask :default => [:spec, :cucumber]"
end
-
end
def add_clearance_gem
View
@@ -0,0 +1,77 @@
+Rails app
+=========
+
+This is a Rails 3.1 app running on Ruby 1.9.2 and deployed to Heroku's Cedar stack. It has an RSpec and Cucumber test suite which should be run before commiting to the master branch.
+
+Laptop setup
+------------
+
+Use our laptop script to get Homebrew, Postgres, Redis, RVM, Ruby 1.9.2, and Bundler:
+
+ https://github.com/thoughtbot/laptop
+
+Use our dotfiles to get commands like `git up` and `git down` for a clean git history:
+
+ https://github.com/thoughtbot/dotfiles
+
+Get the code:
+
+ git clone git@github.com:your-account/your-app.git
+
+Set up the app:
+
+ cd your-app
+ bundle
+ bake db:create
+ bake db:migrate
+
+Running tests
+-------------
+
+Run the whole test suite with:
+
+ bake
+
+Run individual specs like:
+
+ s spec/models/user_spec.rb
+
+Run individual features like:
+
+ cuc features/visitor_signs_in.feature
+
+Tab complete to make it even faster!
+
+When a spec or feature file has many specs in them, you sometimes want to run just what you're working on. In that case, specify a line number:
+
+ s spec/models/user_spec.rb:8
+ cuc features/visitor_signs_in.feature:105
+
+Development process
+-------------------
+
+To run the app in development mode, use Foreman, which was installed from the `laptop` script:
+
+ foreman start
+
+It will pick up on the Procfile and use Thin as the app server instead of Webrick, which will also be used by Heroku's Cedar stack.
+
+ git pull --rebase
+ grb create feature-branch
+ bake
+
+This creates a new branch for your feature. Name it something relevant. Run the tests to make sure everything's passing. Then, implement the feature.
+
+ bake
+ git add -A
+ git commit -m "my awesome feature"
+ git push origin feature-branch
+
+Open up the Github repo, change into your feature-branch branch. Press the "Pull request" button. It should automatically choose the commits that are different between master and your feature-branch. Create a pull request and share the link in Campfire with the team. When someone else gives you the thumbs-up, you can merge into master:
+
+ git up
+ git down
+ git push origin master
+
+For more details and screenshots of the feature branch code review process, read [this blog post](http://robots.thoughtbot.com/post/2831837714/feature-branch-code-reviews).
+
@@ -1,70 +0,0 @@
-Suspenders is a base Rails application that you can upgrade.
-
- ![Suspenders boy](http://media.tumblr.com/1TEAMALpseh5xzf0Jt6bcwSMo1_400.png)
-
-Installation
-------------
-
-First install the suspenders gem:
-
- gem install suspenders
-
-Then run:
-
- suspenders create projectname
-
-This will create a Rails 3 app in `projectname'. This script creates a new
-new git repository. It is not meant to be used against an existing repo.
-
-Gemfile
--------
-
-To see the latest and greatest gems, look at Suspenders'
-[template/trout/Gemfile](https://github.com/thoughtbot/suspenders/blob/master/template/trout/Gemfile),
-which will be copied into your projectname/Gemfile.
-
-It includes application gems like:
-
-* [Paperclip](https://github.com/thoughtbot/paperclip) for file uploads
-* [Formtastic](https://github.com/justinfrench/formtastic) for better forms
-* [Hoptoad Notifier](https://github.com/thoughtbot/hoptoad_notifier) for exception notification
-* [Flutie](https://github.com/thoughtbot/flutie) for default CSS styles
-* [Clearance](https://github.com/thoughtbot/clearance) for authentication
-
-And testing gems like:
-
-* [Cucumber, Capybara, and Akephalos](http://robots.thoughtbot.com/post/1658763359/thoughtbot-and-the-holy-grail) for integration testing, including Javascript behavior
-* [RSpec](https://github.com/rspec/rspec) for awesome, readable isolation testing
-* [Factory Girl](https://github.com/thoughtbot/factory_girl) for easier creation of test data
-* [Shoulda](http://github.com/thoughtbot/shoulda) for frequently needed Rails and RSpec matchers
-* [Timecop](https://github.com/jtrupiano/timecop) for dealing with time
-* [Bourne](https://github.com/thoughtbot/bourne) and Mocha for stubbing and spying
-
-Other goodies
--------------
-
-Suspenders also comes with:
-
-* [jQuery](https://github.com/jquery/jquery) for Javascript pleasantry
-* Rails' flashes set up and in application layout.
-* A few nice time formats.
-
-See [template/files](https://github.com/thoughtbot/suspenders/blob/master/template/files) to
-see what is generated one-time.
-
-Dependencies
-------------
-
-Some gems included in Suspenders have native extensions. You should have GCC installed on your
-machine before running Suspenders.
-If you're running OS X, we recommend the [GCC OSX installer](https://github.com/kennethreitz/osx-gcc-installer).
-We use [Capybara Webkit](https://github.com/thoughtbot/capybara-webkit) for full-stack Javascript integration testing.
-It requires you have QT installed on your machine before running Suspenders.
-Instructions for installing QT on most systems are [available here](https://github.com/thoughtbot/capybara-webkit/wiki/Installing-QT).
-
-
-Issues
-------
-
-If you have problems, please create a [Github issue](https://github.com/thoughtbot/suspenders/issues).
-

0 comments on commit c5ba370

Please sign in to comment.