cmd: add --result-format
cmd: add --result-format

This allows callers to deal with multiple output formats and not require
string parsing in order to understand what the error was. The default
format is "bsd".

Signed-off-by: Aleksa Sarai <a8eb12d32d6ec07cdf737175ec7d4a0f1b4e1ee7@suse.de>

vbatts/go-mtree,vbatts/go-mtree