Skip to content

Instantly share code, notes, and snippets.

@anderssvendal
anderssvendal / dbp
Created December 14, 2010 13:04
Copy a file to the dropbox public folder and copy the link
#!/bin/bash
cp $1 ~/Dropbox/Public/
echo "http://dl.dropbox.com/u/USERID/$1" | pbcopy
@anderssvendal
anderssvendal / alternating.js
Created December 3, 2010 10:48
Make labels alternate between several form fields
(function($)
{
$.fn.extend({
alternating: function(options)
{
var options = options;
var currentElement = -1;
var timeout = 0;
// Create focus and blur events for all inputfields
#!/bin/bash
curl -s http://whatthecommit.com/ | grep "<p>" | sed 's/<p>//' | sed 's/^/"/' | sed 's/$/"/' | xargs git commit -m
@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]);