Revert "Do not use set -e in helper shell scripts"

This reverts commit 0aeb88e663b9b19e173de20b132bef2189c6d7c9.
This commit is contained in:
Vladimir Zhelezov 2020-12-19 13:16:23 +01:00
parent 0ca63ddc84
commit 2a37479d60
2 changed files with 3 additions and 3 deletions

View File

@ -1,10 +1,10 @@
#!/usr/bin/env bash
# Parse hledger's help and output all commands and command aliases in
# parenthesis. Do not output single letter command aliases, it's not useful.
set -uo pipefail
set -euo pipefail
declare commands_help
commands_help=$(hledger) || exit
commands_help=$(hledger)
{
sed -rn 's/^\s+([a-z][-a-z]+)\s+.*/\1/p' <<< "$commands_help"
sed -rn 's/^\s+[a-z][-a-z]+\s+\(([a-z][ ,a-z]+)\).*/\1/p' <<< "$commands_help" |

View File

@ -2,7 +2,7 @@
# Parse hledger's help and output long options. Do not propose single letter
# completions. Options requiring an argument make that explicit by appending the
# equal sign (=)
set -uo pipefail
set -euo pipefail
declare subcommand=${1:-}
declare hledgerArgs=(--help)