Skip to content

mkio 1.4.0

Choose a tag to compare

@markuskimius markuskimius released this 19 Sep 03:38
· 2 commits to main since this release

mkio 1.4.0 makes the command line answer a request for help. A minor release: new --help / -h flags and a help command, all additive. No change to config, the wire protocol, the clients, the expression language or the on-disk layout.

Added

  • mkio --help, -h and mkio help print every command, grouped into server and client commands, and exit 0. Bare mkio prints the same and still exits 1.
  • mkio <command> --help (or -h, or mkio help <command>) describes one command: synopsis, each option, notes and examples. mkio archive --help covers both the row mode and the history-only mode.
  • All help output fits 80 columns; long synopses fold between options rather than running to 130.

Fixed

  • --help was an error everywhere: the top level printed Error: expected a command, got '--help' and exited 1, and every command rejected it as an unknown option.
  • mkio check --help took --help for the url and tried to connect to it.
  • mkio dbupdate --bogus and mkio init --bogus answered "this command takes no options" above a usage line listing their options; they now name the options they take.
  • The top-level usage had drifted from the commands: it omitted dbupdate --keep-redo, showed subpub with a single topic, and gave init no description. Help, error usage lines and the flags each command accepts now come from one table, so they cannot drift again.

Changed

  • An unknown command prints its did-you-mean hint and Run 'mkio --help' instead of the whole usage under it.
  • An argument error prints the command's usage line, folded to 80 columns, and Run 'mkio <command> --help' for details.
  • A command given too few arguments prints its own help and exits 1.

Errors still go to stdout with exit 1. See the README section "Help".