Dotfiles, utilities, and other apparatus.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

31 lines
465 B

#!/usr/bin/env python3
import os
import sqlite3
os.chdir(os.path.join(os.getenv('HOME'), 'notes'))
conn = sqlite3.connect('metadata.db')
c = conn.cursor()
c.execute(
'''CREATE TABLE links (
page text,
target text,
UNIQUE(page, target)
);
'''
)
c.execute(
'''CREATE TABLE pages (
page text,
title text,
datetime text,
UNIQUE(page)
);
'''
)
conn.commit()
conn.close()