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
# 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" | |
# add basic layout to start | |
file 'app/views/layouts/application.html.erb', <<HTML |
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
# mongo_template.rb | |
# fork of Ben Scofield's Rails MongoMapper Template (http://gist.github.com/181842) | |
# | |
# To use: | |
# rails project_name -m http://gist.github.com/408924.txt | |
# remove unneeded defaults | |
run "rm public/index.html" | |
run "rm public/images/rails.png" | |
run "rm public/javascripts/controls.js" |
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
Bundler version 1.0.0 | |
Ruby version 1.9.2p0 (2010-08-18 revision 29036) [x86_64-darwin10.4.0] | |
RVM version 1.0.1 with environment: | |
ruby-1.9.2-p0: | |
system: | |
uname: "Darwin Goliath.local 10.4.0 Darwin Kernel Version 10.4.0: Fri Apr 23 18:28:53 PDT 2010; root:xnu-1504.7.4~1/RELEASE_I386 i386" |
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
# This is an incomplete implementation. | |
module NestedAttributes | |
extend ActiveSupport::Concern | |
module ClassMethods | |
def accepts_nested_attributes_for(*attr_names) | |
options = { :allow_destroy => false } | |
options.update(attr_names.extract_options!) | |
options.assert_valid_keys(:allow_destroy, :reject_if) | |
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 'open-uri' | |
run "rm public/index.html" | |
run "rm .gitignore" | |
rake "db:migrate" | |
file ".gitignore", <<-CODE | |
#{URI.parse("https://raw.github.com/github/gitignore/master/Rails.gitignore").read} | |
*.sublime-workspace | |
CODE |
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
<notextile> | |
<table class="table table-bordered" cellpadding="0" cellspacing="0" style="max-width:600px;"> | |
<tr class="headers"> | |
<th></th> | |
<th>Halogen</th> | |
<th>LED</th> | |
</tr> | |
<tr> | |
<td><b>Bulb Life</b></td> | |
<td>5,000 hours</td> |
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
<div id="ms-embedded-request-form" data-height="400"></div> | |
<script type="text/javascript"> | |
(function(s,o,g,r){ | |
g = s.createElement(o); | |
r = s.getElementsByTagName(o)[0]; | |
g.type = 'text/javascript'; | |
g.async = 1; | |
g.src = 'http://assets.mosquitosquad.com/embed-form/embed.js'; | |
r.parentNode.insertBefore(g, r); | |
})(document, 'script'); |
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
// swap the keybindings for paste and paste_and_indent | |
{ "keys": ["super+v"], "command": "paste_and_indent" }, | |
{ "keys": ["super+shift+v"], "command": "paste" } |
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
/* Extend the Underscore object with the following methods */ | |
// Rate limit ensures a function is never called more than every [rate]ms | |
// Unlike underscore's _.throttle function, function calls are queued so that | |
// requests are never lost and simply deferred until some other time | |
// | |
// Parameters | |
// * func - function to rate limit | |
// * rate - minimum time to wait between function calls | |
// * async - if async is true, we won't wait (rate) for the function to complete before queueing the next request |
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
{ | |
"app/adapters/*.js": { | |
"command": "adapter", | |
"template": [ | |
"import ApplicationAdapter from './application';", | |
"", | |
"export default ApplicationAdapter.extend({", | |
"", | |
"});" | |
], |
OlderNewer