Skip to content

Instantly share code, notes, and snippets.

View wyattdanger's full-sized avatar

Stephen Bush wyattdanger

View GitHub Profile
(function() {
var __bind = function(fn, me){ return function(){ return fn.apply(me, arguments); }; };
$(function() {
var Map, NomsApp, infoBox, nom, textBox;
if (!navigator.geolocation) {
alert('bro you need geolocation');
}
textBox = $('#text');
infoBox = $("#infoBox");
Map = (function() {
@for $i from 0 through 8
h2.spinner-#{$i}
background-position: 0px $i*400px
@wyattdanger
wyattdanger / poppa-on-coffee.coffee
Created August 22, 2011 20:29
big poppa on coffee
$.poppa
'a[href^=http]': ( a ) ->
# do cool stuff with a
'ul.tabs': ( ul ) ->
# do cool stuff with ul
'#fancy-page': ( page ) ->
# do fancy stuff on page
@wyattdanger
wyattdanger / poppa-on-node.js
Created August 22, 2011 20:08
Poppa on specific node
$('header').poppa({
'li': function (li) {
// $('header').find('li')
// is accessible within this function as li
},
'a:first-of-type': function (a) {
// $('header').find('a:first-of-type')
// is accessible within this function as a
}
});
/* Before Big Poppa */
if ( $('ul.tabs').size() ) {
// do stuff
}
if ( $('a[href^=http]').size() ) {
// do stuff
}
#unbind C-b
set-option -g prefix C-w
bind-key C-w last-window
set -g base-index 1
set-option -g default-terminal "screen-256color"
# act like vim
setw -g mode-keys vi
bind h select-pane -L
bind j select-pane -D
This is the source for my blog.
@wyattdanger
wyattdanger / .tmux.conf
Created August 12, 2011 16:00
my tmux configuration
# This sets default key to control-a instead of control-b.
# I also recommend remapping caps lock to control in system preferences
set-option -g prefix C-a
bind-key C-w last-window
set -g base-index 1
set-option -g default-terminal "screen-256color"
# act like vim
setw -g mode-keys vi
bind h select-pane -L
@wyattdanger
wyattdanger / tmux.conf
Created August 12, 2011 16:00
my tmux configuration
# This sets default key to control-a instead of control-b.
# I also recommend remapping caps lock to control in system preferences
set-option -g prefix C-a
bind-key C-w last-window
set -g base-index 1
set-option -g default-terminal "screen-256color"
# act like vim
setw -g mode-keys vi
bind h select-pane -L
var geocoder = require('geocoder');
// Geocoding
geocoder.geocode("Atlanta, GA", function ( err, data ) {
// do stuff with data
});
// Reverse Geocoding
geocoder.reverseGeocode( 33.7489, -84.3789, function ( err, data ) {
// do stuff with data