Skip to content

Instantly share code, notes, and snippets.

View virtadpt's full-sized avatar
💭
First thing that Microsoft does when buying Github: Add statuses. Whee.

The Doctor virtadpt

💭
First thing that Microsoft does when buying Github: Add statuses. Whee.
View GitHub Profile
# Author: Pieter Noordhuis
# Description: Simple demo to showcase Redis PubSub with EventMachine
#
# Update 7 Oct 2010:
# - This example does *not* appear to work with Chrome >=6.0. Apparently,
# the WebSocket protocol implementation in the cramp gem does not work
# well with Chrome's (newer) WebSocket implementation.
#
# Requirements:
# - rubygems: eventmachine, thin, cramp, sinatra, yajl-ruby
@virtadpt
virtadpt / rhi-mesh-01.md
Created November 13, 2012 23:27 — forked from boxysean/rhi-mesh-01.md
Red Hook Initiative mesh update: first edition

This is the first of periodic updates I'll make as I gather information.

About

Internet connectivity is largely out in Red Hook. (Open question: How out?) A collection of initiatives are working together to rapidly build infrastructure to provide free, reliable Internet connectivity to Red Hook.

The goal of this project is twofold: to provide Internet connectivity in the short-term for the disaster relief effort, and to create an infrastructure for future disaster responses.

Groups involved:

@virtadpt
virtadpt / gist:3230577
Created August 1, 2012 20:47 — forked from loki42/gist:2349796
multilingual python web app with babel
# get all langs from db
all_available_languages = [a['lang'] for a in cur.fetchall()]
def get_lang(lang):
default = 'en'
mo_dir = os.path.join(os.path.abspath(os.curdir), 'locale')
domain = 'musicfilmcomedy'
langs = [lang.replace('-', '_')]
langs.append(default)
@virtadpt
virtadpt / README.md
Created February 16, 2012 17:10 — forked from thedod/README.md
Demagnetizr - Tweetable magnet urls