Reference
Configuration
Logs are a rolling window. Two optional settings in .memex/config.json decide how much of it is kept.
The file
memex init creates .memex/config.json. Both keys are optional, and a missing file means the defaults. In a worktree, the main checkout’s file applies, since every worktree shares its log store.
# .memex/config.json
{ "max_logs_mb": 10, "keep_logs": "2w" }max_logs_mb
The size cap for the whole store, every stream together, in whole MiB. Default 10. After each memex log, if the entries total more than the cap, memex deletes the oldest until they fit. The entry just written is never deleted.
keep_logs
An age limit, off unless set. Set, it deletes every entry older than it before the size cap applies; with both set, both apply. It takes Nm, Nh, Nd, Nw or forever.
When a value is wrong
An invalid value prints one warning naming the key and disables only its own limit; the other still applies. A config that can’t be read, isn’t a JSON object, or has an unknown key prints a warning and prunes nothing at all.
Pruning happens only when memex log writes; reads never delete. What is still true belongs in a README, a header or a collection.