fix: derive default release channel from package.json

This commit is contained in:
Michael Vines 2018-11-30 07:49:40 -08:00
parent 7437c3f694
commit 96133216e5
1 changed files with 5 additions and 3 deletions

View File

@ -1,6 +1,8 @@
#!/usr/bin/env bash
set -e
channel=$(cd "$(dirname "$0")"; node -p 'require("../package.json")["solana-channel"]')
usage() {
exitcode=0
if [[ -n "$1" ]]; then
@ -24,7 +26,9 @@ Operate a local testnet
update/up-specific options:
edge - Update/start the "edge" channel network
beta - Update/start the "beta" channel network (default)
beta - Update/start the "beta" channel network
Default channel: $channel
down-specific options:
none
@ -42,8 +46,6 @@ EOF
cmd="$1"
shift
channel=beta
docker --version || usage "It appears that docker is not installed"
case $cmd in
update)