Skip to content

Instantly share code, notes, and snippets.

@ask-compu
Last active September 10, 2015 00:42
Show Gist options
  • Save ask-compu/4ad008ee432c505e1add to your computer and use it in GitHub Desktop.
Save ask-compu/4ad008ee432c505e1add to your computer and use it in GitHub Desktop.
import sqlite3 as lite
import os
conn = lite.connect(os.path.join(os.path.expanduser('~/.phenny'), 'seen.db'))
c = conn.cursor()
c.execute('''create table if not exists seen(
nick varchar(31) NOT NULL PRIMARY KEY,
channel varchar(31) NOT NULL,
message text,
event varchar(10) NOT NULL,
time time DATETIME DEFAULT CURRENT_TIMESTAMP NOT NULL,
);''')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment