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
var margin = {top: 1, right: 1, bottom: 6, left: 1}, | |
width = 960 - margin.left - margin.right, | |
height = 500 - margin.top - margin.bottom; | |
var formatNumber = d3.format(",.0f"), | |
format = function(d) { return formatNumber(d) + " TWh"; }, | |
color = d3.scale.category20(); |
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
var gia = (function (obj){ | |
var stateEV=[["Alabama","AL",9,"SR"],["Alaska","AK",3,"SR"],["Arizona","AZ",11,"SR"],["Arkansas","AR",6,"SR"],["California","CA",55,"SO"],["Colorado","CO",9,"T"],["Connecticut","CT",7,"LO"],["Delaware","DE",3,"SO"],["Dist. of Columbia","DC",3,"SO"],["Florida","FL",29,"T"],["Georgia","GA",16,"SR"],["Hawaii","HI",4,"SO"],["Idaho","ID",4,"SR"],["Illinois","IL",20,"SO"],["Indiana","IN",11,"SR"],["Iowa","IA",6,"T"],["Kansas","KS",6,"SR"],["Kentucky","KY",8,"SR"],["Louisiana","LA",8,"SR"],["Maine","ME",4,"SO"],["Maryland","MD",10,"SO"],["Massachusetts","MA",11,"SO"],["Michigan","MI",16,"LO"],["Minnesota","MN",10,"SO"],["Mississippi","MS",6,"SR"],["Missouri","MO",10,"LR"],["Montana","MT",3,"SR"],["Nebraska","NE",5,"SR"],["Nevada","NV",6,"T"],["New Hampshire","NH",4,"T"],["New Jersey","NJ",14,"SO"],["New Mexico","NM",5,"SO"],["New York","NY",29,"SO"],["North Carolina","NC",15,"T"],["North Dakota","ND",3,"SR"],["Ohio","OH",18,"T"],["Oklahoma","OK",7,"SR"],["Oregon","OR",7,"SO"],["Pennsylvan |
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
filetype off | |
"call pathogen#helptags() | |
call pathogen#runtime_append_all_bundles() | |
" first clear any existing autocommands: | |
autocmd! | |
set nocompatible | |
" http://items.sjbach.com/319/configuring-vim-right |
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 enqueue_for_migrant_work(okey, root, source) | |
queue_name = "migrant_worker_$$$ENVIRONMENTNAME$$$" | |
payload = { | |
'processor' => 'SetRootAndSourceProjectIdsProcessor', | |
'okey' => okey, | |
'root' => root, | |
'source' => source, | |
} |
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
# Controller | |
class GuestsController < ApplicationController | |
def create | |
@guest = Guest.new(params[:guest]) | |
if @guest.save | |
redirect_to :action => 'index' | |
else | |
render :action => 'new' | |
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
export TERM="xterm-color" | |
alias ls="ls -G" | |
WHITE="\[\033[0;37m\]" | |
DARK_GREY="\[\033[0;30m\]" | |
LIGHT_BLUE="\[\033[0;34m\]" | |
LIGHT_GREEN="\[\033[0;32m\]" | |
export PS1="\n$DARK_GREY[$LIGHT_BLUE\w$DARK_GREY]$LIGHT_GREEN\$ $WHITE" |
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
class BTree | |
attr_reader :order | |
class Node | |
attr_reader :keys, :values, :branches | |
def initialize(order, values = {}) | |
@order = order | |
@keys = values.keys.sort |
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
command GrepWord :execute 'grep -r --exclude=metrics/coverage/* --exclude=*.log --exclude=*.*-base --exclude=vendor/* --exclude=*.tmp '.expand('<cword>').' *' | :copen | :cc | |
nnoremap <c-j> :cnext<CR> :norm! zz<cr> | |
nnoremap <c-k> :cprev<CR> :norm! zz<cr> | |
nnoremap <c-n> :tabnew<CR> | |
nnoremap <c-l> :tabnext<CR> | |
nnoremap <c-h> :tabprev<CR> |
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
[~]$ ruby -e "require 'rubygems'; require 'sinatra'" | |
/Library/Ruby/Site/1.8/rubygems.rb:578:in `report_activate_error': Could not find RubyGem memcache-client (>= 0) (Gem::LoadError) | |
from /Library/Ruby/Site/1.8/rubygems.rb:134:in `activate' | |
from /Library/Ruby/Site/1.8/rubygems.rb:158:in `activate' | |
from /Library/Ruby/Site/1.8/rubygems.rb:157:in `each' | |
from /Library/Ruby/Site/1.8/rubygems.rb:157:in `activate' | |
from /Library/Ruby/Site/1.8/rubygems.rb:158:in `activate' | |
from /Library/Ruby/Site/1.8/rubygems.rb:157:in `each' | |
from /Library/Ruby/Site/1.8/rubygems.rb:157:in `activate' | |
from /Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' |
OlderNewer