Skip to content

Instantly share code, notes, and snippets.

@kaezarrex
kaezarrex / post-receive
Created Feb 13, 2014
post-receive deploy hook
View post-receive
#!/bin/bash
build="build-branch"
build_dir="/build/path"
while read oldrev newrev refname
do
branch=$(git rev-parse --symbolic --abbrev-ref $refname)
if [ "$build" == "$branch" ]; then
GIT_WORK_TREE=$build_dir git checkout -f $build
View index.html
<!doctype html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, user-scalable=no">
<link href="style.css" rel="stylesheet" type="text/css">
</head>
<body>
<div id="google_canvas"></div>
<script src="http://code.jquery.com/jquery-2.0.3.min.js"></script>
@kaezarrex
kaezarrex / blocks-thumbnail
Last active Aug 29, 2015
bl.ocks.org thumbnail creator
View blocks-thumbnail
#! /bin/bash
echo $1
convert "$1" -thumbnail 230x120 -gravity center -background white -extent 230x120 thumbnail.png
@kaezarrex
kaezarrex / brewer.ipynb
Created Apr 13, 2014
brewer (bokeh example)
View brewer.ipynb
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@kaezarrex
kaezarrex / README.md
Last active Aug 29, 2015
NC State Wolfline arrivals graph
View README.md

The transit data comes through my proxy from the TransLoc OpenAPI. Routes are represented as large, colored nodes. Stops are small, gray nodes. Edges represent the minimum arrival prediction between a given stop and all vehicles on a given route.

The code needs refactoring.

@kaezarrex
kaezarrex / README.md
Last active Aug 29, 2015
GTFS Shapes
View README.md
@kaezarrex
kaezarrex / index.html
Last active Aug 29, 2015
GTFS Shapes and Stops
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset='utf-8'>
</head>
<body>
<script src='http://d3js.org/d3.v3.min.js'></script>
<script src='http://d3js.org/topojson.v1.min.js'></script>
<script src='main.js'></script>
</body>
View keybase.md

Keybase proof

I hereby claim:

  • I am kaezarrex on github.
  • I am kaezarrex (https://keybase.io/kaezarrex) on keybase.
  • I have a public key whose fingerprint is 9CC4 5C65 D3D2 1AE5 A2FB B998 29DD A6EB 4275 E5A7

To claim this, I am signing this object:

@kaezarrex
kaezarrex / SaS.js
Last active Aug 29, 2015
Sanford And Son Theme Song
View SaS.js
// http://wavepot.com/
var b = makeNote(987.77);
var a = makeNote(880);
var fSharp = makeNote(739.99);
var f = makeNote(698.46);
var d = makeNote(587.33);
var _ = makeNote(0);
var rate = 4;
@kaezarrex
kaezarrex / index.html
Last active Aug 29, 2015
Chart and Table
View index.html
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>D3 Chart and Table</title>
<link rel="stylesheet/less" type="text/css" href="style.less">
<script src="http://cdnjs.cloudflare.com/ajax/libs/less.js/1.7.1/less.min.js" type="text/javascript"></script>
</head>
<body>
<svg class="chart"></svg>
You can’t perform that action at this time.