Skip to content

f4rkh4d/ephemeral

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ephemeral

demo notes that auto-delete after a ttl. because not every thought deserves to be kept forever.

i kept writing 2am: check tz bug on sticky notes, then forgetting to remove them for 3 months. so i built this. now every note i take has a timer on it, and the old stuff vanishes on its own.

install

pip install git+https://github.com/f4rkh4d/ephemeral

python 3.10+. sqlite lives at ~/.ephemeral/store.db by default, or wherever EPHEMERAL_STORE points.

usage

ephemeral add "check the tz bug in parser"          # default 24h
ephemeral add "grab bread on the way home" --ttl 3h
ephemeral add "recipe for tushonka" --persist        # no ttl, sticks around
ephemeral ls
ephemeral gc
ephemeral export -o dump.txt
ephemeral rm 7

ls fades older notes toward violet as they approach expiry, so glancing at the list tells you what's about to disappear.

how it works

sqlite table with created_at and expires_at. every command runs a sweep first, so expired notes are gone before you see the list. --persist stores null for expires_at and the gc query ignores those rows. that's the whole trick.

caveats

ttl parsing is deliberately strict. i won't accept 1 hour or 1hr or 90 minutes. just 30s, 45m, 3h, 7d. write me an issue if that's annoying and i'll loosen it.

haven't tested on windows. probably works, the paths use pathlib, but ymmv.

license

mit. see LICENSE.

About

notes that auto-delete. because not every thought deserves to be kept.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages