Skip to content

Instantly share code, notes, and snippets.

@meshulam
meshulam / tempodb-export.py
Last active August 29, 2015 14:01
Export script for TempoDB
# Script to export TempoDB data.
# Relies on TempoDB python client v1.0: https://github.com/tempodb/tempodb-python/tree/v1.0
import datetime
import os
import re
import json
import uuid
from tempodb.client import Client
import datetime
import dateutil.parser
import optparse
from Queue import Queue
import tempodb
from threading import Thread
class Worker(Thread):
"""Thread executing tasks from a given tasks queue"""
def __init__(self, tasks):
@meshulam
meshulam / zimbra.txt
Last active December 11, 2015 18:39
This bookmarklet recites the current URL as Dadaist sound poetry. It just removes all non-letters from the URL and passes it to the Google Translate text-to-speech service in Italian mode (it's funniest that way). It doesn't work on all sites, probably because of some sort of cross-site referral limitations on Google's part. Tested in Safari and…
javascript:(function(){ var s=location.href.replace(/[^A-Za-z]/g,'');var url='http://translate.google.com/translate_tts?ie=UTF-8&tl=it&q='+s; console.log(url); var a=document.createElement('audio');a.setAttribute('src',url);a.play();}())