Skip to content

Instantly share code, notes, and snippets.

Ezekiel Templin ezkl

Block or report user

Report or block ezkl

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View gist:794003
# routes.rb
resources :clients do
resources :payments
end
# views/clients/index.html.haml
= link_to 'New Payment', new_client_payment_path(client)
# controllers/payments_controller.rb
def new
View gist:804682
flat_namespace -lruby.1.9.1 -lsybdb -lpthread -ldl -lobjc
ld: in /Developer/SDKs/MacOSX10.6.sdk/usr/local/lib/libiconv.2.dylib, missing required architecture x86_64 in file
collect2: ld returned 1 exit status
make: *** [tiny_tds.bundle] Error 1
View gist:804753
flat_namespace -lruby.1.9.1 -lsybdb -lpthread -ldl -lobjc
ld: in /Developer/SDKs/MacOSX10.6.sdk/usr/local/lib/libiconv.2.dylib, missing required architecture x86_64 in file
collect2: ld returned 1 exit status
make: *** [tiny_tds.bundle] Error 1
@ezkl
ezkl / benchpress.md
Created Feb 7, 2011
Nokogiri HTML Parsers - BenchPress Results
View benchpress.md

Nokogiri Parser Comparisons

Author: Ezekiel Templin
Date: February 06, 2011
Summary: Comparing Nokogiri's parsers

System Information

Operating System:    Mac OS X 10.6.6 (10J567)
CPU:                 Intel Core i7 2.66 GHz
@ezkl
ezkl / ua_collection.rb
Created Mar 15, 2011
Collect UA's from UserAgentString. Store in Redis.
View ua_collection.rb
require "ohm"
require "typhoeus"
require "nokogiri"
Ohm.connect
class UserAgent < Ohm::Model
attribute :user_agent
index :user_agent
@ezkl
ezkl / gist:1059685
Created Jul 2, 2011
distance_of_time_ago & time_ago_in_words
View gist:1059685
ruby-1.9.2-p180 :018 > class Ack
ruby-1.9.2-p180 :019?> include ActionView::Helpers::DateHelper
ruby-1.9.2-p180 :020?> end
=> Ack
ruby-1.9.2-p180 :021 > dh = Ack.new
=> #<Ack:0x00000101dfb018>
ruby-1.9.2-p180 :022 > dh.time_ago_in_words("2011-05-05 19:49:46")
=> "about 1 month"
ruby-1.9.2-p180 :023 > dh.distance_of_time_in_words_to_now("2011-05-05 19:49:46")
=> "about 1 month"
@ezkl
ezkl / update_textmate.sh
Created Jul 2, 2011
Textmate SVN update
View update_textmate.sh
#!/usr/bin/env bash
mkdir -p /Library/Application\ Support/TextMate/
sudo chown -R $(whoami) /Library/Application\ Support/TextMate
cd /Library/Application\ Support/TextMate/
if [[ -d Bundles/.svn ]] ; then
cd Bundles && svn up
View float.sh
#!/usr/bin/env bash
echo $1 + $2 | bc
View Color Picker Pro_2011-09-14-181210_ezkl.crash
Process: Color Picker Pro [35572]
Path: /Applications/Color Picker Pro.app/Contents/MacOS/Color Picker Pro
Identifier: com.fructivity.colorpickerpro
Version: 1.0.1 (1.0.1)
Code Type: X86-64 (Native)
Parent Process: launchd [331]
Date/Time: 2011-09-14 18:12:04.444 -0400
OS Version: Mac OS X 10.6.8 (10K549)
Report Version: 6
@ezkl
ezkl / git-remote-output.md
Created Sep 27, 2011 — forked from bcg5017/new remote -v
The output of `git remote -v`
View git-remote-output.md

fetch is where you update from

git fetch origin master == fetch any updates from the remote repository called origin's master branch.

OR

git pull origin master == fetch any updates AND merge them into mine

origin	git@github.com:ezkl/code.ipsrvcs.com.git (fetch)

push is where you put your updates

You can’t perform that action at this time.