alias hue_blue='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=blue"'
alias hue_cyan='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=cyan"'
alias hue_green='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=green"'
alias hue_indigo='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=indigo"'
alias hue_lavender='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=lavender"'
alias hue_orange='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=orange"'
alias hue_pink='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=pink"'
alias hue_red='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on&color=red"'
alias hue_white='curl -s "http://10.255.2.251/cgi-bin/hue.cgi?user=jameswhite&action=all_on"'
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 paginator | |
if @pager.number_of_pages>1 | |
p = "<div id='paginator'>" | |
p << link_to("1", {:page => 1}, :title => "Page 1")+" " if @pager.number_of_pages>7 and @page.number>4 | |
p << "... " if @pager.number_of_pages>8 and @page.number>5 | |
p << link_to(@page.number-6, {:page => @page.number-6}, :title => "Page " + (@page.number-6).to_s)+" " if @page.number>6 and @pager.number_of_pages<@page.number+1 | |
p << link_to(@page.number-5, {:page => @page.number-5}, :title => "Page " + (@page.number-5).to_s)+" " if @page.number>5 and @pager.number_of_pages<@page.number+2 | |
p << link_to(@page.number-4, {:page => @page.number-4}, :title => "Page " + (@page.number-4).to_s)+" " if @page.number>4 and @pager.number_of_pages<@page.number+3 | |
p << link_to(@page.number-3, {:page => @page.number-3}, :title => "Page " + (@page.number-3).to_s)+" " if @page.number>3 | |
p << link_to(@page.number-2, {:page => @page.number-2}, :title => "Page " + (@page.number-2).to_s)+" " if @page.number> |
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
module Spec::Example::ExampleGroupMethods | |
def currently(name, &block) | |
it("*** CURRENTLY *** #{name}", &block) | |
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
require 'autotest/redgreen' | |
require 'autotest/timestamp' | |
require '~/autotest/sound/sound.rb' | |
Autotest::Sound.sound_path = "~/autotest/sound/sound_fx/current/" | |
Autotest.add_hook :initialize do |at| | |
%w{.svn .hg .git vendor db index public tmp log}.each {|exception|at.add_exception(exception+'/')} | |
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
/Volumes/share/audio/mp3/wilson_picket/a_man_and_a_half_disc_1$ musicdns 01_i_found_a_love_the_falcons.mp3 | |
/opt/local/lib/ruby/gems/1.8/gems/earworm-0.0.2/lib/earworm/fingerprint.rb:79:in `id3_info_for': undefined method `[]' for nil:NilClass (NoMethodError) | |
from /opt/local/lib/ruby/gems/1.8/gems/earworm-0.0.2/lib/earworm/fingerprint.rb:29:in `to_hash' | |
from /opt/local/lib/ruby/gems/1.8/gems/earworm-0.0.2/lib/earworm/client.rb:16:in `identify' | |
from /Users/rick/bin/musicdns:14 |
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
#!/bin/sh -x | |
CURRENT=`git branch | grep '\*' | awk '{print $2}'` | |
git checkout master | |
git pull origin master | |
git checkout ${CURRENT} | |
git rebase master |
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 git-svn-repo? { | |
git branch -r 2>/dev/null | awk '{if ($1=="git-svn") {exit 0} else {exit 1}}' | |
} | |
function git-agnostic-pull { | |
if $(git-svn-repo?); then | |
git svn rebase | |
else | |
git pull origin master | |
fi |
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
~/git/words-music-new on master $ type ts | |
ts is a function | |
ts () | |
{ | |
AUTOTEST=${1:-.} autotest | |
} |
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
15:51 vinbarnes: pipe surveyor | |
15:52 vinbarnes: pipe miser | |
15:52 vinbarnes: pipe roper | |
16:02 rickbradley: pipe sprayer | |
16:17 vinbarnes: pipe peddler | |
16:22 rickbradley: pipe strapper | |
16:30 vinbarnes: pipe gobbler | |
16:31 rickbradley: pipe fitter | |
16:31 rickbradley: pipe fiddler | |
16:34 vinbarnes: pipe cocotte |
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
~$ freshtrack mbm --after 2008-09-01 | |
/opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:59:in `times_to_dates': undefined method `to_date' for "Commad 'lst' ukow":String (NoMethodError) | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:55:in `each' | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:55:in `times_to_dates' | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:50:in `condense_time_data' | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:46:in `convert_time_data' | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:41:in `get_time_data' | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:78:in `get_data' | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/lib/freshtrack.rb:82:in `track' | |
from /opt/local/lib/ruby/gems/1.8/gems/freshtrack-0.2.1/bin/freshtrack:23 |