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() { | |
'use strict'; | |
/** | |
* Simple event bubbling callback generator. | |
* Usage: | |
* | |
* this.listenTo(view, 'some:event', Marionette.bubbleEvent('some:other:event')); | |
* | |
* @param {String} eventName The event name of the event triggered. Can be the |
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
if (!Function.prototype.bind) { | |
Function.prototype.bind = function() { | |
var args = _.toArray(arguments); | |
args.unshift(this); | |
return _.bind.apply(null, args); | |
} | |
} |
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
# ~/.osx — http://mths.be/osx | |
############################################################################### | |
# General UI/UX # | |
############################################################################### | |
# Set computer name (as done via System Preferences → Sharing) | |
scutil --set ComputerName "mba-gbsice" | |
scutil --set HostName "mba-gbsice" | |
scutil --set LocalHostName "mba-gbsice" |
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
# encoding: utf-8 | |
class String | |
# The extended characters map used by contains_accent. The accented characters | |
# are coded here using their numerical equivalent to sidestep encoding issues. | |
# These correspond to ISO-8859-1 encoding. | |
ACCENTS_MAPPING = { | |
'E' => [200,201,202,203], | |
'e' => [232,233,234,235], | |
'A' => [192,193,194,195,196,197], |