Skip to content

Instantly share code, notes, and snippets.

View sligodave's full-sized avatar

David Higgins sligodave

View GitHub Profile
@sligodave
sligodave / five_alive.py
Created June 22, 2012 20:05
Keep five process running at almost all time for one minute.
import multiprocessing
import time
from os import getpid
def worker():
pid = getpid()
print 'START %d' % pid
time.sleep(3)
@sligodave
sligodave / filter_through_command.py
Created May 3, 2012 15:57 — forked from jefftriplett/filter_through_command.py
Sublime Text 2: "Filter Through Command" plugin
# saved from: http://pastie.org/private/bclbdgxzbkb1gs2jfqzehg
import sublime
import sublime_plugin
import subprocess
class RunExternalCommand(sublime_plugin.TextCommand):
"""
Runs an external command with the selected text,
@sligodave
sligodave / gist:2359553
Created April 11, 2012 14:14
User a list of when all users joined.
from datetime import datetime
#########################################
# Set up the django environment
#########################################
from django.core.management import setup_environ