Skip to content

Instantly share code, notes, and snippets.

View zachseifts's full-sized avatar
🏠
Working from home

Zach Seifts zachseifts

🏠
Working from home
  • Appalachian State University
  • Boone, NC
View GitHub Profile
#!/usr/bin/env python
from sauce import Twitter
def write_heyer(replies):
last_reply_id = str(replies[len(replies)-1].id)
hf = open('.heyer', 'w')
hf.write(last_reply_id)
hf.close()
#!/usr/bin/env python2.5
## WARNING: This file is generated
#!/usr/bin/env python
"""Create a "virtual" Python installation
"""
import sys
import os
import optparse
import shutil
class Person(models.Model):
name = models.CharField(_('name'), max_length=128)
parent = models.ForeignKey('self')
# parent, assuming this person is spontaneously created
fred = Person(name='Fred')
# me and my brothers
zach = Person.objects.get_or_create(name='Zach', parent=fred)
trevor = Person.objects.get_or_create(name='Trevor', parent=fred)
<?php
/** Function fixing a title
*
* On the homepage for Wall to Wall Photos (and I guess other pages) the
* rotating image's title is fucked up and it's really annoying me. Here's
* a function that should fix it.
*
* That way if a title is `IMG_S4_500` it would be transformed into
* 'No Title'. When a title is `file_name` it will be transformed into
cd ~/.virtualenvs
virtualenv --no-site-packages booneweather
source ./booneweather/bin/activate
cd booneweather
git clone http://github.com/zachseifts/tweetbot.git
pip install -r ./tweetbot/requirements.txt
cd ~/.virtualenvs/booneweather/lib/python2.X/site-packages
ln -s ~/.virtualenvs/booneweather/tweetbot
from tweetbot import bot
#! /bin/sh
### BEGIN INIT INFO
# Provides: redis-server
# Required-Start: $syslog
# Required-Stop: $syslog
# Should-Start: $local_fs
# Should-Stop: $local_fs
# Default-Start: 2 3 4 5
# Default-Stop: 0 1 6
# Short-Description: redis-server - Persistent key-value db
// Connect to the database.
try {
if (!window.openDatabase) {
alert('This browser does not support window.openDatabase, boo!');
} else {
var shortName = 'eightA';
var version = '0.1';
var displayName = 'eightA Climbs Database';
var maxSize = 1024*1024;
var db = window.openDatabase(shortName, version, displayName, maxSize);
server {
listen 22.22.22.22:80;
server_name www.mysite.com;
rewrite ^/(.*) http://mysite.com/$1 permanent;
}
server {
listen 22.22.22.22:80;
server_name mysite.com;