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

This commit is contained in:
Michael Vines
2019-07-01 11:54:00 -07:00
committed by GitHub
parent d7ed3b8024
commit 19ea5fe0c0
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
}