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
#!/usr/bin/env ruby | |
require 'base64' | |
require 'open-uri' | |
# file or url | |
def get_css(src) | |
if src.start_with? 'http' | |
src = src.gsub('|', '%7C') | |
STDERR.puts "# GET #{src}" | |
# simulate modern browser to get woff |
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
grep -n5 bootstrap-sass Gemfile.lock | |
13- specs: | |
14- jquery-datatables-rails (1.11.2) | |
15- jquery-rails | |
16- | |
17-GIT | |
18: remote: git://github.com/thomas-mcdonald/bootstrap-sass.git | |
19- revision: 571ba865e1cd01f583c5949446803b9f2cd21926 | |
20- branch: 3 | |
21- specs: |
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
# Patch for ransack (https://github.com/ernie/ransack) to use scopes | |
# Helps migrating from Searchlogic or MetaSearch | |
# Place this file into config/initializer/ransack.rb of your Rails 3.2 project | |
# | |
# Usage: | |
# class Debt < ActiveRecord::Base | |
# scope :overdue, lambda { where(["status = 'open' AND due_date < ?", Date.today]) } | |
# end | |
# | |
# Ransack out of the box ignores scopes. Example: |
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
[GEM_ROOT]/bundler/gems/rpm-a063acda8e06/lib/new_relic/agent/stats_engine/transactions.rb:61 | |
[GEM_ROOT]/bundler/gems/rpm-a063acda8e06/lib/new_relic/agent/instrumentation/action_controller_subscriber.rb:104 | |
[GEM_ROOT]/bundler/gems/rpm-a063acda8e06/lib/new_relic/agent/instrumentation/action_controller_subscriber.rb:51 | |
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/fanout.rb:96 | |
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/fanout.rb:40 | |
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/fanout.rb:40 | |
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/fanout.rb:40 | |
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/instrumenter.rb:36 | |
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications/instrumenter.rb:25 | |
[GEM_ROOT]/gems/activesupport-4.0.0/lib/active_support/notifications.rb:159 |
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 'resque_mailer' | |
require 'devise/async' | |
# pop and set locale from the args before running | |
module PerformWithLocale | |
def perform(*args) | |
I18n.with_locale(args.pop) do | |
super(*args) | |
end | |
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
diff --git a/vendor/assets/javascripts/photobox.js b/vendor/assets/javascripts/photobox.js | |
index 8d4f9a9..b7ed7f5 100644 | |
--- a/vendor/assets/javascripts/photobox.js | |
+++ b/vendor/assets/javascripts/photobox.js | |
@@ -14,6 +14,7 @@ | |
transitionend = "transitionend webkitTransitionEnd oTransitionEnd MSTransitionEnd", | |
isOldIE = !('placeholder' in doc.createElement('input')), | |
isIE = !!win.ActiveXObject, | |
+ isOpera = (win.navigator.appName == 'Opera'), | |
isMobile = 'ontouchend' in doc, |
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
angular.module('myApp').factory 'FormHelper', [-> | |
class FormHelper | |
constructor: (scope, object, formName) -> | |
@scope = scope | |
@formName = formName | |
@object = -> @scope[object] | |
scope.$watch "#{formName}.$pristine", (pristine) => | |
@unsaved = !pristine | |
@saved = false unless pristine | |
scope.$watch "#{formName}.$valid", (valid) => |
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
<?xml version="1.0" encoding="UTF-8"?> | |
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | |
<plist version="1.0"> | |
<dict> | |
<key>KeepAlive</key> | |
<false/> | |
<key>Label</key> | |
<string>homebrew.mxcl.redis</string> | |
<key>ProgramArguments</key> | |
<array> |
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
Chrome 26.0 (Mac) railsResourceFactory singular should be able to delete to arbitrary url FAILED | |
Error: Expected DELETE /xyz with different headers | |
EXPECTED: {"test":{"id":123,"abc":"xyz","xyz":"abc"}} | |
GOT: {"Accept":"application/json"} | |
at Error (<anonymous>) | |
at $httpBackend (/Users/glebm/angularjs-rails-resource/test/lib/angular/angular-mocks.js:931:15) | |
at sendReq (/Users/glebm/angularjs-rails-resource/test/lib/angular/angular.js:9980:9) | |
at $http.serverRequest (/Users/glebm/angularjs-rails-resource/test/lib/angular/angular.js:9757:16) | |
at wrappedCallback (/Users/glebm/angularjs-rails-resource/test/lib/angular/angular.js:7303:59) | |
at wrappedCallback (/Users/glebm/angularjs-rails-resource/test/lib/angular/angular.js:7303:59) |
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
#!/usr/bin/env ruby | |
# coding: utf-8 | |
require 'net/http' | |
require 'json' | |
# a simple wrapper to do an HTTPS GET | |
def fetch_uri(url) | |
STDERR.puts "GET #{url}" if ENV['VERBOSE'] | |
uri = URI(url) |