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
### Keybase proof | |
I hereby claim: | |
* I am bradly on github. | |
* I am bradly (https://keybase.io/bradly) on keybase. | |
* I have a public key whose fingerprint is 0490 C1ED 7D4F 4A2F 8B03 6D1C 8AFB 954D F7EE 3A2C | |
To claim this, I am signing this object: |
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
› cd ~/code | |
2.0.0-p481 in code/ | |
› ember new wheres-waldo | |
Future versions of Ember CLI will not support v0.10.30. Please update to Node 0.12 or io.js. | |
version: 0.2.2 | |
Could not find watchman, falling back to NodeWatcher for file system events. | |
Visit http://www.ember-cli.com/#watchman for more info. | |
installing | |
create .bowerrc |
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
#!/usr/bin/env ruby | |
spec = Gem::Specification.new do |s| | |
s.name = %q{event_calendar_engine} | |
s.version = "0.2.15" | |
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version= | |
s.authors = ["Jason LaPier", "Jeremiah Heller"] | |
s.date = %q{2011-09-09} | |
s.description = %q{Provides basic event management features with versioned history of changes.} |
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
require 'uri' | |
class RootRelativeFilter < HTML::Pipeline::Filter | |
def call | |
doc.search("img").each do |img| | |
next if img['src'].nil? | |
src = img['src'].strip | |
if src.start_with? '/' | |
img["src"] = URI.join(context[:base_url], src).to_s |
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
package main | |
import "fmt" | |
import "os" | |
func main() { | |
source_dir_path := "/some/dir" | |
destination_dir_path := "/some/other/dir" | |
ensure_source_directory_exists(source_dir_path) |
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
ruby -e 'puts `curl -s https://gist.githubusercontent.com/bradly/9b0536bd532718a0d22c/raw/d17a2106679a9f4034ba508ef388bf30b23ee54c/gistfile1.txt`.scan(/../).map { |c| c.hex.chr }.join' |
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
e299a5efb88f2049276c6c20626520746865726520696e207468652066696e657374205475657364617920737765617465722120e299a5efb88f |
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
buffer = '' | |
cipher = nil | |
render :text => proc { |response, output| | |
s3.get(bucket, key_path) do |chunk| | |
# decrypt chunk | |
if buffer == '' | |
# first chunk | |
buffer << chunk | |
# extract the magic string and salt | |
magic_test = buffer.slice!(0..EncryptionHelper.magic_string.length-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
module ActiveRecordSingleton | |
def self.included(base) | |
base.class_eval do | |
class << self | |
delegate :attributes, :save, :save!, :update_attribute, :update_attributes, :update_attributes!, :update_column, to: 'instance' | |
[:new, :create, :create!, :destroy, :destroy_all, :delete, :delete_all].each do |method_name| | |
undef_method method_name | |
end |
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
<?php | |
// TimThumb script created by Tim McDaniels and Darren Hoyt with tweaks by Ben Gillbanks | |
// http://code.google.com/p/timthumb/ | |
// MIT License: http://www.opensource.org/licenses/mit-license.php | |
/* Parameters allowed: */ | |
// w: width |
NewerOlder