Shunning
Not logged in
Bounty program for improvements to Tcl and certain Tcl packages.

Shunning is the process of preventing unwanted data from entering a vault.

All unwanted data is specified by a set of uuids, i.e. content hashes, stored in a shun database.

The system provides two applications to manage shunning, one to create and extend the database of shunned content, the other a filter taking a stream of paths and uuids and removing all shunned elements from it before passing it on.

lspace-shun

Syntax: lspace-shun ?/path/to/shun-database?

The application reads a stream of paths and their uuids from the standard input and adds all unknown uuids to the specified shun database.

lspace-shun-state

Syntax: lspace-shun-state ?/path/to/shun-database?

This application prints the current state of the shun database.

lspace-filter-shunned

Syntax: lspace-filter-shunned ?/path/to/shun-database?

The application reads a stream of uuids from the standard input and provides a filtered stream on its standard output, with all entries whose uuid is found in the specified shun database dropped from the stream.

Note that while the command assumes that the uuid is the first element of each entry in the stream the remaining elements can be anything. Accepted entries are passed through in total.

Shun database

Common to both applications, if no database is specified the environment variable [LSPACE_SHUN](ev.md) is consulted. If this environment variable does not exist, or is empty, then the default shun database at $HOME/.local/lspace/shun.sqlite is used.