yet more dotfiles

This commit is contained in:
osmarks
2025-07-28 11:19:15 +01:00
parent 3fe5d0a9de
commit 23f58cc0d4
2 changed files with 23 additions and 3 deletions
+3 -3
View File
@@ -1,6 +1,6 @@
import sqlite3
import sqlite3, sys
longterm = sqlite3.connect("/data/archive/lthist.sqlite3")
longterm = sqlite3.connect(sys.argv[1])
longterm.executescript(f"""
CREATE TABLE IF NOT EXISTS places (
guid TEXT PRIMARY KEY,
@@ -33,4 +33,4 @@ ON CONFLICT DO UPDATE SET lastModified = excluded.lastModified, title = excluded
# TODO: possibly wrong with new profile, might need to increment historyvisits or something
longterm.execute("INSERT INTO historyvisits SELECT (moz_historyvisits.id || '/' || visit_date), moz_places.guid, visit_date, visit_type FROM moz_historyvisits JOIN moz_places ON moz_places.id = moz_historyvisits.place_id ON CONFLICT DO NOTHING;")
longterm.commit()
longterm.commit()