The sound distributed version control system

#725 Improve argument parsing for `pijul log --output-format`

Opened by chevyparakeet on November 8, 2022
chevyparakeet on November 8, 2022

At present, there is no indication of which formats are accepted, and no error handling. Pijul should indicate which formats are available and give error feedback if an unknown format is requested.

chevyparakeet added a change on November 8, 2022
Parse argument of `pijul log --output-format` strictly by 7qFsmcJTAmyi5DxiNk265yTyKeTGNeoqjQfzksWAeGkH, created on November 7, 2022
7P7G4J5ZT4S5BP6VAN226Z7CRZXEEVO5YHJ6IFMW27NHBR5TDJRAC
chevyparakeet on November 8, 2022

The above patch implements the suggested changes; --output-format now validates its input to accept plaintext or json as an argument, and the argument parser exposes this expectation to users.