Skip to content

Instantly share code, notes, and snippets.

View mxmilkiib's full-sized avatar
🔊

Milkii Brewster mxmilkiib

🔊
View GitHub Profile
@mxmilkiib
mxmilkiib / purge_quassel_db-sqlite.sh
Created May 20, 2025 17:53 — forked from nurupo/purge_quassel_db-sqlite.sh
Weekly purge of Quassel chat database for sqlite instances
#!/bin/sh
# Taken from http://blog.encomiabile.it/2011/02/03/prune-quassel-database/
# Taken from https://gist.github.com/Und3rf10w/36a2034cb2c8eafbfb801c1a89e1f8bc
BAK_PATH="${HOME}/.config/quassel-irc.org/quassel-storage.sqlite.bak"
CURRENT_PATH="${HOME}/.config/quassel-irc.org/quassel-storage.sqlite"
# first day of data that will be maintained
# -7 day means that *every* chatline stored before 8 days ago and so on are going to be eliminated.
# only the last 7 days are keeped.
DATE_TO_PRUNE='-7 day'