This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import json | |
import urllib | |
import sys | |
def fetch_pages(): | |
i = 1 | |
while True: | |
result = urllib.urlopen('http://search.twitter.com/search.json?%s' % ( |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; -*- emacs-lisp -*- | |
(when (load "flymake" t) | |
(defun flymake-pyflakes-init () | |
(let* ((temp-file (flymake-init-create-temp-buffer-copy | |
'flymake-create-temp-inplace)) | |
(local-file (file-relative-name | |
temp-file | |
(file-name-directory buffer-file-name)))) | |
(list "/Users/jyrki/.emacs-lib/pychecker.sh" (list local-file)))) | |
(add-to-list 'flymake-allowed-file-name-masks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! perl -w | |
# http://triplefusion.net/system/macosx-clipboard | |
# ---------------------------------------------------------------------- | |
# File: macosx-clipboard | |
# ---------------------------------------------------------------------- | |
# | |
# All portions of code are copyright by their respective author/s. | |
# Copyright (c) 2006 Samuel Ljungkvist <salj@triplefusion.net> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/perl | |
# Author: Bart Trojanowski <bart@jukie.net> | |
# Website: http://www.jukie.net/~bart/blog/urxvt-url-yank | |
# License: GPLv2 | |
use strict; | |
use warnings; | |
my $url_matcher = qr{( | |
(?:https?://|ftp://|news://|mailto:|spotify:|file://|www\.)[ab-zA-Z0-9\-\@;\/?:&=%\$_.+!*\x27(),~#]+ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(defun single-window-mode () | |
(interactive) | |
(delete-other-windows) | |
(set-frame-size (selected-frame) 80 65)) | |
(defun double-window-mode () | |
(interactive) | |
(delete-other-windows) | |
(set-frame-size (selected-frame) 163 65) | |
(split-window (selected-window) 83 t)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys | |
import time | |
from tornado.ioloop import IOLoop | |
def printer(digit): | |
def _do_print(): | |
print digit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Enable tab completion | |
import rlcompleter | |
import pdb | |
pdb.Pdb.complete = rlcompleter.Completer(locals()).complete | |
# Sometimes when you do something funky, you may lose your terminal echo. This | |
# should restore it when spanwning new pdb. | |
import termios, sys | |
termios_fd = sys.stdin.fileno() | |
termios_echo = termios.tcgetattr(termios_fd) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
echo "Bieberizing. Please wait..." | |
git reset --soft `git log --pretty=oneline | tail -n 1 | awk '{ print $1 }'`; git commit --amend -m "Implemented the software as specified." --author="Justin Bieber <justin@taiste.fi>" | |
echo "Done & Done" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'sass' | |
module Sass::Script::Functions | |
def inline_image(image, type) | |
path = image.value | |
image_data = [data(path)].flatten.pack('m').gsub('\n', '') | |
declaration = "url('data:#{type};base64,#{image_data}')" | |
Sass::Script::String.new(declaration) | |
end | |
declare :inline_image, :args => [:string, :string] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[couchdb] | |
database_dir = tmp/couch | |
view_index_dir = tmp/couch | |
[httpd] | |
port = 8922 | |
bind_address = 127.0.0.1 | |
[log] | |
file = tmp/couch.log |