Skip to content

Instantly share code, notes, and snippets.

@anderssvendal
anderssvendal / paulirish.user.js
Created November 10, 2010 15:32
Userscript to remove canvas from paulirish.com
// ==UserScript==
// @match http://*.paulirish.com/*
// @match http://www.paulirish.com/*
// ==/UserScript==
(document.getElementsByTagName('canvas')[0]).parentElement.removeChild(document.getElementsByTagName('canvas')[0]);
#!/bin/bash
curl -s http://whatthecommit.com/ | grep "<p>" | sed 's/<p>//' | sed 's/^/"/' | sed 's/$/"/' | xargs git commit -m
@lucasfais
lucasfais / gist:1207002
Created September 9, 2011 18:46
Sublime Text 2 - Useful Shortcuts

Sublime Text 2 – Useful Shortcuts (Mac OS X)

General

⌘T go to file
⌘⌃P go to project
⌘R go to methods
⌃G go to line
⌘KB toggle side bar
⌘⇧P command prompt
@anderssvendal
anderssvendal / time_formatter.coffee
Created November 2, 2011 08:15
Relative time formatting
TimeFormatter =
to_pretty: (date)->
now = new Date()
date = new Date(date)
# Time ago in seconds
a = (now - date) / 1000
if a is 0 then 'akkurat nå'
else if a is 1 then 'ett sekund siden'
@JeffreyWay
JeffreyWay / gist:1525217
Created December 27, 2011 21:29
Instant Server for Current Directory
alias server='open http://localhost:8000 && python -m SimpleHTTPServer'
@anderssvendal
anderssvendal / sass.rb
Created June 11, 2012 10:19
Simple retina backgrounds with sass
require 'sass_extensions'