revbank

Prepaid bar tab payment system for hackerspaces


Usage

revbank [--datadir <dir>] [--plugindir <dir>] [--command <cmd>]
revbank [--datadir <dir>] --with-lock cmd arg...
revbank --help
revbank --man  # Like --help, but more information (requires perldoc)

Description

This document only describes how to run revbank. The main documentation is in README.md.

Options

  • -c, --command

    Takes a single command line and executes it without entering the RevBank shell. The command line is parsed as input on the top-level RevBank prompt. Example: --command 'give quux 0.42 "description here"; xyzzy'.

  • --with-lock

    Takes the remaining command line arguments (use -- to stop processing) and executes them as a system command, which may involve executing a shell; see "system" in perlfunc for details.

    Useful for running external programs (e.g. backup scripts) which need a consistent/atomic view of the data directory, but will block all RevBank usage until the program is over.

    Example: --with-lock -- tar -czf revbank-data.tgz ~/.datadir

  • --datadir

    Overrides REVBANK_DATADIR

  • --plugindir

    Overrides REVBANK_PLUGINDIR

  • --help, --man

    View documentation: either just the options (--help) or the entire man page (--man).

Environment

Some environment variables are boolean. Non-existent variables, empty variables, and variables equal to 0 are considered false. All other values are considered true, but it is customary to just use 1 (something like yes could lead someone to believe that no would be false).

  • REVBANK_DATADIR

    Specifies the data directory, defaults to ~/.revbank. Will be created and populated if it does not already exist.

  • REVBANK_PLUGINDIR

    Specifies the directory for plugins that are listed without paths in $REVBANK_DATADIR/plugins. Defaults to plugins in the directory of the revbank executable.

  • REVBANK_DEBUG

    When true, makes RevBank print more details, like what happens with hidden accounts. Don't use in production, because those accouns are hidden for a reason.

  • REVBANK_SKIP_LOCK

    When true, disables file locking. Necessary when calling RevBank from a program that already holds the lock, but otherwise just a bad idea. Use with caution.

  • REVBANK_JSON

    Requires the json plugin. Set to lines or array for JSONL or single-array JSON output, for integrating RevBank in external software. Note that although the normal output is suppressed, not everything is available as JSON information, so it's only usable for specific use cases that are deemed possible.

  • REVBANK_STATIEGELD

    Requires the statiegeld plugin. When true, starts RevBank in deposit return mode, which means that scanned products will be container returns instead of purchases. See "statiegeld.md" in plugins for details.

See also

Further documentation is available in README.md, INSTALLING.md, UPGRADING.md, and all the .md files in the RevBank repository.

Author

Juerd Waalboer #####@juerd.nl