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
# Gemfile: | |
group :development do | |
gem 'guard' | |
gem 'guard-coffeescript' | |
end |
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
# Guardfile | |
group 'frontend' do | |
guard 'coffeescript', :output => 'public/javascripts/compiled' do | |
watch(%r{^app/coffeescripts/.+\.coffee$}) | |
end | |
end |
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
bundle exec guard |
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
1 is 1 | |
# true | |
1 is "1" | |
# false |
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
<form id="new_post" action="/articles" method="post"> | |
<input type="submit" formaction="/articles/preview" formmethod="get" value="Aperçu" /> | |
</form> | |
<input type="submit" form="new_post" value="Publier" /> |
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
require "bundler/capistrano" | |
# allowing shell interactions | |
default_run_options[:pty] = true | |
# multistaging | |
set :stages, %w(staging production) | |
set :default_stage, "staging" | |
require 'capistrano/ext/multistage' |
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
set :rails_env, "production" | |
role :web, "" | |
role :app, "" | |
role :db, "", :primary => true |
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 'capistrano' | |
gem 'capistrano-ext' |
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
$ bundle install --binstubs | |
$ bin/capify . | |
$ mkdir config/deploy | |
$ cp config/environments/production.rb config/environments/staging.rb | |
$ cap staging deploy:setup |
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
$ cap staging deploy:cold |