This file contains hidden or 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
[rails2] > ./script/generate migration AddNameToPerson | |
exists db/migrate | |
create db/migrate/20100210021747_add_name_to_person.rb | |
[rails3] > rails generate migration AddNameToPerson | |
invoke active_record | |
create db/migrate/20100210021747_add_name_to_person.rb |
This file contains hidden or 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
[rails2] > ./script/generate resource Person name:string | |
exists app/models/ | |
exists app/controllers/ | |
exists app/helpers/ | |
create app/views/people | |
exists test/functional/ | |
exists test/unit/ | |
exists test/unit/helpers/ | |
dependency model | |
exists app/models/ |
This file contains hidden or 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
[rails2] > ./script/generate model Person name:string | |
exists app/models/ | |
exists test/unit/ | |
exists test/fixtures/ | |
create app/models/person.rb | |
create test/unit/person_test.rb | |
create test/fixtures/people.yml | |
exists db/migrate | |
create db/migrate/20100210021556_create_people.rb |
This file contains hidden or 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
[rails2] > ./script/generate controller People index show | |
exists app/controllers/ | |
exists app/helpers/ | |
create app/views/people | |
exists test/functional/ | |
exists test/unit/helpers/ | |
create app/controllers/people_controller.rb | |
create test/functional/people_controller_test.rb | |
create app/helpers/people_helper.rb | |
create test/unit/helpers/people_helper_test.rb |
This file contains hidden or 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
apply "http://gist.github.com/187990.txt" | |
apply "http://gist.github.com/187993.txt" |
This file contains hidden or 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 gems | |
gem 'cucumber' | |
gem 'webrat' | |
# generate Cucumber infrastructure | |
run './script/generate cucumber' |
This file contains hidden or 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
# remove Prototype defaults | |
run "rm public/javascripts/controls.js" | |
run "rm public/javascripts/dragdrop.js" | |
run "rm public/javascripts/effects.js" | |
run "rm public/javascripts/prototype.js" | |
# add XHTML 1.0 Strict layout, with jQuery from Google | |
file 'app/views/layouts/application.html.erb', <<-ERB | |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en"> |
This file contains hidden or 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
# mongo_template.rb | |
# remove unneeded defaults | |
run "rm public/index.html" | |
run "rm public/images/rails.png" | |
run "rm public/javascripts/controls.js" | |
run "rm public/javascripts/dragdrop.js" | |
run "rm public/javascripts/effects.js" | |
run "rm public/javascripts/prototype.js" |
This file contains hidden or 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
/* GitHub Commits, version 0.0.1 | |
* (c) 2009 Jeff Rafter | |
* | |
* Based on GitHub Badge by Dr Nic Williams (but with the good code removed) | |
* | |
* You need: jquery.js, md5.js | |
* | |
* See http://pajhome.org.uk/crypt/md5 for more info. | |
* | |
*--------------------------------------------------------------------------*/ |
