mirror of
https://github.com/Retropex/bitcoin.git
synced 2025-05-12 19:20:42 +02:00
contrib: Fix gen-bitcoin-conf.sh
.
In #31118, the format of bitcoind's `--help` output changed slightly in a way that breaks `gen-bitcoin-conf.sh`, modify the script to accomodate the new format, by starting after the line that says "Options:" and strip the `-help` option and its description from the output.
This commit is contained in:
parent
aa68ed27b8
commit
a24419f8be
@ -50,7 +50,8 @@ EOF
|
||||
# adding newlines is a bit funky to ensure portability for BSD
|
||||
# see here for more details: https://stackoverflow.com/a/24575385
|
||||
${BITCOIND} --help \
|
||||
| sed '1,/Print this help message and exit/d' \
|
||||
| sed '1,/Options:/d' \
|
||||
| sed -E '/^[[:space:]]{2}-help/,/^[[:space:]]*$/d' \
|
||||
| sed -E 's/^[[:space:]]{2}\-/#/' \
|
||||
| sed -E 's/^[[:space:]]{7}/# /' \
|
||||
| sed -E '/[=[:space:]]/!s/#.*$/&=1/' \
|
||||
|
Loading…
Reference in New Issue
Block a user