Skip to content

Instantly share code, notes, and snippets.

piscisaureus /
Created August 13, 2012 16:12
Checkout github pull requests locally

Locate the section for your github remote in the .git/config file. It looks like this:

[remote "origin"]
	fetch = +refs/heads/*:refs/remotes/origin/*
	url =

Now add the line fetch = +refs/pull/*/head:refs/remotes/origin/pr/* to this section. Obviously, change the github url to match your project's URL. It ends up looking like this:

goatslacker / gist:6004481
Created July 15, 2013 23:36
time tracking local
" Lets me know how much time I've spent editing a file
" Keyboard shortcut -> \dt
augroup TimeSpentEditing
au BufWinEnter * if !exists('b:tstart')|let b:tstart=reltime()|en
augroup END
function! TimeSpentEditing()
let secs = str2nr(reltimestr(reltime(b:tstart)))
let hours = secs / 3600
jburks725 / gist:1ad9d8a14a1351941bc8
Last active January 19, 2018 01:37
Firebase pros and cons

So here's what I have for Firebase pros and cons so far:


  • Autoscaling built-in
  • Can start for free (only need to start paying once we hit 50 connections)
  • Robust APIs for Javascript (including several frameworks like Angular), iOS, and Android
  • Built-in support for authentication services like Facebook, Google, and Twitter
  • Declarative Security Rules model allows us to enforce read/write privileges and data validation throughout the tree