-
The -j option of the application generator accepts an arbitrary string. If passed "foo", the gem "foo-rails" is added to the Gemfile, and the application JavaScript manifest requires "foo" and "foo_ujs". As of this writing "prototype-rails" and "jquery-rails" exist and provide those files via the asset pipeline. Default is "jquery". [fxn]
-
jQuery is no longer vendored, it is provided from now on by the jquery-rails gem. [fxn]
-
Prototype and Scriptaculous are no longer vendored, they are provided from now on by the prototype-rails gem. [fxn]
-
The scaffold controller will now produce SCSS file if Sass is available [Prem Sichanugrist]
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
[user] | |
name = Scott Chacon | |
email = [email protected] | |
[alias] | |
serve = !git daemon --reuseaddr --verbose --base-path=. --export-all ./.git | |
unstage = reset HEAD | |
lol = log --pretty=oneline --abbrev-commit --graph --decorate | |
branches = !git-branches | |
st = status | |
[gui] |
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
<h2>Management & Office Staff</h2> | |
<ul class="employees"> | |
<r:employees:collection container="list" order="show_order" employee_type="managers"> | |
<r:name_link /> | |
</r:employees:collection> | |
</ul> |
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
alias lola='git log --graph --decorate --pretty=oneline --abbrev-commit' |
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 'timecop' | |
module TemporalHelpers | |
# Travels to +time+ and lets the clock keep running. | |
# | |
# If a block is given, executes the block at that | |
# time then returns to the present. | |
def travel_to(time, &block) | |
Timecop.travel Time.parse(time), &block |
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 'spec/runner/formatter/base_text_formatter' | |
require 'spec/runner/formatter/no_op_method_missing' | |
module Spec | |
module Runner | |
module Formatter | |
class ImmediateFailureFormatter < BaseTextFormatter | |
include NOOPMethodMissing | |
def example_failed(example, counter, failure) |
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
def create | |
@post = @huddle.posts.build(params[:post]) | |
@post.user = current_user | |
deliver_post if @post.save | |
respond_with @post | |
end | |
private |
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
def as_json(options={}) | |
# TODO: users.count and rating_sum are generating way too may queries, | |
# we should do something about them. | |
{ | |
:latitude => latitude, | |
:longitude => longitude, | |
:title => title, | |
:id => id, | |
:users => users.count, | |
:cap => distance_cap, |
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 a bit non-DRY | |
// XXX Check how to properly refactor. | |
var AxAutocompletes = function () { | |
// Javascript permite nesting. Es mejor que nada quede definido en la parte externa. | |
var split = function (val) { return val.split( /,\s*/ ); } | |
var extractLast = function (term) { return split(term).pop(); } | |
// lift del $.bind |
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
var simplified = { visibility: 'simplified' }; | |
var style = { | |
'minimal': [ | |
{ featureType: 'all', | |
stylers: [{ visibility: 'off' }] }, | |
{ featureType: 'water', | |
stylers: [{ hue: 0 }, { visibility: 'on' }, { lightness: 0 }, { saturation: 0 }] }, | |
{ featureType: 'water', elementType: 'label', stylers: [simplified] }, |
OlderNewer