Rework fullnode.sh to recover better from genesis block resets (#4884) (#4888)

automerge
This commit is contained in:
mergify[bot]
2019-07-01 12:31:53 -07:00
committed by Grimes
parent 462d0cfc6c
commit 6089db2a07
2 changed files with 135 additions and 128 deletions

View File

@@ -88,3 +88,18 @@ default_arg() {
args+=("$name")
fi
}
replace_arg() {
declare name=$1
declare value=$2
default_arg "$name" "$value"
declare index=0
for arg in "${args[@]}"; do
index=$((index + 1))
if [[ $arg = "$name" ]]; then
args[$index]="$value"
fi
done
}