Skip to content

Instantly share code, notes, and snippets.

View bkeating's full-sized avatar
🤙
Gettin’ SUM & CALCin’ out

Benjamin Keating bkeating

🤙
Gettin’ SUM & CALCin’ out
View GitHub Profile
@bkeating
bkeating / rangen.py
Last active August 29, 2015 14:10
Generate a range of random 'codes' for Santa on the Square photo service
import random
import string
import subprocess
from PIL import Image
from PIL import ImageFont
from PIL import ImageDraw
codes = []
for i in range(1, 251):
@bkeating
bkeating / etcc-meetup-012915.md
Created January 29, 2015 14:52
Computer Club Meetup notes for Getting Things Done with Python on Jan 29th 02015

Getting Things Done with Python

@bkeating
bkeating / bpk_workshop_weather.ino
Created March 20, 2015 19:46
Ben's Workshop Weather. Arduino sketch to push DHT11 sensor data to data.sparkfun.com
#include <SPI.h>
#include <Ethernet.h>
#include "DHT.h"
#define DHTPIN 2
#define DHTTYPE DHT11
DHT dht(DHTPIN, DHTTYPE);
byte mac[] = {
@bkeating
bkeating / etcc-metup-020150521-lock-picking.md
Last active August 29, 2015 14:21
Notes related to ETCC's first Lock Picking meetup

Lock Picking 101

Lock Picking 101 is an East Troy Computer Club meetup event held on May 21, 02015 located on the historic village square of East Troy, Wisconsin. http://etcc.io/

General Announcements / News

Software [you need to try]

@bkeating
bkeating / etcc-meetup-020150730-home-automation.md
Last active August 29, 2015 14:26
Notes related to ETCC's meetup on home automation. http://etcc.io/

Managing Your Music, Pictures and Home Videos

...

# Depends on the OS X "say" command
import time, datetime, subprocess, math, sys
def say(s):
subprocess.call(['say', str(s)])
def seconds_until(dt):
return time.mktime(dt.timetuple()) - time.time()
# -*- coding: utf-8 -*-
import datetime as dt
import dateutil.parser as dparser
import urllib2
from BeautifulSoup import BeautifulSoup
print "<?xml version=\"1.0\" encoding=\"utf-8\"?>"
print "<articles>"
# Loop through each prediction and bet URL.
@bkeating
bkeating / gunicorn_upstart.conf
Created September 13, 2011 17:17
An example of my Upstart script that can start/stop a Django project.
# PROJECT_NAME.conf - run PROJECT_NAME gunicorninstances
#
# This runs gunicorn_django for PROJECT_NAME; to install:
# * sudo ln -s <this file> /etc/init/PROJECT_NAME.conf
# * sudo initctl reload-configuration
# to use:
# * sudo start/stop/restart/reload/status PROJECT_NAME
#
# For a full list of configuration options: http://gunicorn.org/configure.html