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
| // http://stackoverflow.com/questions/3503660/upgrading-with-parameter-on-a-link-to-remote-in-rails-3 | |
| // http://railsforum.com/viewtopic.php?id=42215 | |
| // http://stackoverflow.com/questions/2508213/rails3-link-to-with-attribute | |
| $$('a[data-remote=true]').each(function(a){ | |
| a.onclick = function(){ | |
| href = a.getAttribute('href'); | |
| url = href.split('?')[0]; | |
| params = href.split('?')[1]; | |
| newParam = encodeURI(eval(a.getAttribute('data-with'))); |
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
| gem pristine --all --no-extensions |
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
| Some brief instructions on how to use Sprocket 2 in Rails to get CoffeeScript | |
| powered JS and SASS powered CSS with YUI compression all via the magic of rack. | |
| This stuff will be native in Rails 3.1 and the layout of the files on the | |
| filesystem will be different but this guide will get you working with it | |
| while we wait for all that to finalize. | |
| Ignore the number prefixes on each file. This is just to ensure proper order in the Gist. | |
| It's based on eric1234 gist https://gist.github.com/911003. ijust made it 3.1 compliant in terms of convention |
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
| // http://www.elijahmanor.com/2011/07/filterbydata-jquery-plugin.html | |
| // https://gist.github.com/1048942 | |
| (function($) { | |
| /* by Elijah Manor with collaboration from Doug Neiner | |
| * Filter results by html5 data attributes either at | |
| * design or at runtime | |
| * | |
| * Usages: |
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
| ActionController::RoutingError (No route matches "/webconsole"): | |
| lib/rack/runtime.rb:18:in `call' | |
| Rendered /home/stan/.rvm/gems/ruby-1.9.2-p290@skeleton/gems/actionpack-3.0.9/lib/action_dispatch/middleware/templates/rescues/routing_error.erb within rescues/layout (1.3ms) |
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
| Only in 3.1.1/blank/app: assets | |
| Only in 3.1.1/blank/app/mailers: .gitkeep | |
| Only in 3.1.1/blank/app/models: .gitkeep | |
| diff -U 0 -r 3.0.9/blank/app/views/layouts/application.html.erb 3.1.1/blank/app/views/layouts/application.html.erb | |
| --- 3.0.9/blank/app/views/layouts/application.html.erb 2011-10-12 15:17:34.853020000 +0900 | |
| +++ 3.1.1/blank/app/views/layouts/application.html.erb 2011-10-12 15:23:26.162309000 +0900 | |
| @@ -5,3 +5,3 @@ | |
| - <%= stylesheet_link_tag :all %> | |
| - <%= javascript_include_tag :defaults %> | |
| - <%= csrf_meta_tag %> |
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
| javascript:window.location='onepassword://'+window.location.href.substring(window.location.href.indexOf('//')+2) |
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
| module Mongoid | |
| module Undo | |
| extend ActiveSupport::Concern | |
| included do | |
| include Mongoid::Document | |
| field :version, type: Integer, default: 0 | |
| before_save :prepare_versioning | |
| after_save :create_version |
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
| build_package_combined_patch() { | |
| local package_name="$1" | |
| { | |
| curl https://github.com/funny-falcon/ruby/compare/p385...p385_falcon_gc.diff | patch -p1 | |
| autoconf | |
| ./configure --prefix="$PREFIX_PATH" $CONFIGURE_OPTS | |
| make -j 8 | |
| make install | |
| } >&4 2>&1 |
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
| build_package_combined_patch() { | |
| local package_name="$1" | |
| { | |
| curl https://raw.github.com/skaes/rvm-patchsets/master/patchsets/ruby/1.9.3/p392/railsexpress | xargs -I % curl https://raw.github.com/skaes/rvm-patchsets/master/patches/ruby/1.9.3/p392/% | patch -p1 | |
| autoconf | |
| ./configure --prefix="$PREFIX_PATH" $CONFIGURE_OPTS | |
| make -j 8 | |
| make install | |
| } >&4 2>&1 |