Skip to content

Instantly share code, notes, and snippets.

@CaptainFrog
CaptainFrog / db.py
Created April 28, 2016 16:00
DatabaseHandler Python
import sqlite3
class Database():
"""Database Helper class"""
def __init__(self):
self.conn = None
def connect(self, filename):
""" Connect the databse handler to a databse """
@CaptainFrog
CaptainFrog / hcd.sh
Last active November 3, 2015 17:54
Local Project cmd
# Bring back to nearest git directory
# todo limit number of up to "/"
function hcd {
if [ ! -d .git ]; then
up 1 ; hcd
fi;
}
# cd doc
function cdoc {
hcd; cd doc;