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
module ActiveRecord::ConnectionAdapters::SchemaStatements | |
def add_foreign_key(from_table, from_column, to_table) | |
constraint_name = "fk_#{from_table}_#{to_table}" | |
execute "alter table #{from_table} add constraint \ | |
#{constraint_name} foreign key (#{from_column}) references #{to_table}(id)" | |
end | |
def set_auto_increment(table_name, number) | |
execute "ALTER TABLE #{quote_table_name(table_name)} AUTO_INCREMENT=#{number}" | |
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
function append(elem, value) { | |
if (typeof value == 'string') { | |
elem.innerHTML = value.replace(/\r\n/g, "\n").replace(/\n/g, '<br />') | |
} else if (typeof value == 'undefined') { | |
} else if (value.constructor == Array) { | |
for (var v in value) {arguments.callee(elem, value[v])} | |
} else { | |
elem.appendChild(value) | |
} | |
return elem |
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
# Copy database.yml | |
run "cp config/database.yml config/database.example.yml" | |
# Delete unnecessary files | |
run "rm README" | |
run "rm public/index.html" | |
# Install plugins | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git', :submodule => true | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git', :submodule => 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
# Copy database.yml | |
run "cp config/database.yml config/database.example.yml" | |
# Delete unnecessary files | |
run "rm README" | |
run "rm public/index.html" | |
# Install plugins | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git', :submodule => true | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git', :submodule => 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
run 'rm public/index.html' | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git' | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git' | |
plugin 'cucumber', :git => 'git://github.com/aslakhellesoy/cucumber.git' | |
plugin 'webrat', :git => 'git://github.com/brynary/webrat.git' | |
plugin 'i18n_generators', :git => 'git://github.com/amatsuda/i18n_generators.git' | |
plugin 'ssl_requirement', :git => 'git://github.com/rails/ssl_requirement.git' | |
plugin 'exception_notification', :git => 'git://github.com/rails/exception_notification.git' | |
plugin 'paperclip', :git => 'git://github.com/thoughtbot/paperclip.git' |
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
run 'rm public/index.html' | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git' | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git' | |
plugin 'cucumber', :git => 'git://github.com/aslakhellesoy/cucumber.git' | |
plugin 'webrat', :git => 'git://github.com/brynary/webrat.git' | |
plugin 'i18n_generators', :git => 'git://github.com/amatsuda/i18n_generators.git' | |
plugin 'ssl_requirement', :git => 'git://github.com/rails/ssl_requirement.git' | |
plugin 'exception_notification', :git => 'git://github.com/rails/exception_notification.git' | |
plugin 'paperclip', :git => 'git://github.com/thoughtbot/paperclip.git' |
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
run 'rm public/index.html' | |
run 'README' | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git' | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git' | |
plugin 'cucumber', :git => 'git://github.com/aslakhellesoy/cucumber.git' | |
plugin 'webrat', :git => 'git://github.com/brynary/webrat.git' | |
plugin 'i18n_generators', :git => 'git://github.com/amatsuda/i18n_generators.git' | |
plugin 'ssl_requirement', :git => 'git://github.com/rails/ssl_requirement.git' | |
plugin 'exception_notification', :git => 'git://github.com/rails/exception_notification.git' |
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
run 'rm public/index.html' | |
run 'README' | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git' | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git' | |
plugin 'cucumber', :git => 'git://github.com/aslakhellesoy/cucumber.git' | |
plugin 'webrat', :git => 'git://github.com/brynary/webrat.git' | |
plugin 'i18n_generators', :git => 'git://github.com/amatsuda/i18n_generators.git' | |
plugin 'ssl_requirement', :git => 'git://github.com/rails/ssl_requirement.git' | |
plugin 'exception_notification', :git => 'git://github.com/rails/exception_notification.git' |
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
run 'rm public/index.html' | |
run 'README' | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git' | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git' | |
plugin 'cucumber', :git => 'git://github.com/aslakhellesoy/cucumber.git' | |
plugin 'webrat', :git => 'git://github.com/brynary/webrat.git' | |
plugin 'i18n_generators', :git => 'git://github.com/amatsuda/i18n_generators.git' | |
plugin 'ssl_requirement', :git => 'git://github.com/rails/ssl_requirement.git' | |
plugin 'exception_notification', :git => 'git://github.com/rails/exception_notification.git' |
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
run 'rm public/index.html' | |
run 'README' | |
plugin 'rspec', :git => 'git://github.com/dchelimsky/rspec.git' | |
plugin 'rspec-rails', :git => 'git://github.com/dchelimsky/rspec-rails.git' | |
plugin 'cucumber', :git => 'git://github.com/aslakhellesoy/cucumber.git' | |
plugin 'webrat', :git => 'git://github.com/brynary/webrat.git' | |
plugin 'i18n_generators', :git => 'git://github.com/amatsuda/i18n_generators.git' | |
plugin 'ssl_requirement', :git => 'git://github.com/rails/ssl_requirement.git' | |
plugin 'exception_notification', :git => 'git://github.com/rails/exception_notification.git' |
OlderNewer