Skip to content

Commit

Permalink
fix(ci): fix scripts after rebase.
Browse files Browse the repository at this point in the history
  • Loading branch information
vldm committed Sep 15, 2021
1 parent 5132695 commit 7be5209
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 20 deletions.
4 changes: 2 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
branches:
only:
- /^v\d+\.\d+/ # release builds
- /^v\d+\.\d+\-[a-z0-9]*/ #pre release builds
- /^v\d+\.\d+\.\d+/ # release builds
- /^v\d+\.\d+\.\d+-[a-z0-9]*/ #pre release builds

notifications:
email: false
Expand Down
41 changes: 23 additions & 18 deletions scripts/cargo-install-all.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,20 +26,27 @@ maybeReleaseFlag=--release
validatorOnly=

while [[ -n $1 ]]; do
if [[ ${1:0:1} = - ]]; then
if [[ $1 = --debug ]]; then
maybeReleaseFlag=
buildVariant=debug
shift
elif [[ $1 = --validator-only ]]; then
validatorOnly=true
shift
if [[ ${1:0:1} = - ]]; then
if [[ $1 = --debug ]]; then
maybeReleaseFlag=
buildVariant=debug
shift
elif [[ $1 = --validator-only ]]; then
validatorOnly=true
shift
else
usage "Unknown option: $1"
fi
elif [[ ${1:0:1} = \+ ]]; then
maybeRustVersion=$1
shift
else
installDir=$1
shift
fi
done


if [[ -z "$installDir" ]]; then
usage "Install directory not specified"
exit 1
Expand All @@ -62,7 +69,6 @@ if [[ $CI_OS_NAME = windows ]]; then
velas-install
velas-install-init
velas-keygen
evm-utils
evm-bridge
)
else
Expand All @@ -85,7 +91,6 @@ else
velas-keygen
velas-test-validator
velas-validator
evm-utils
evm-bridge
)

Expand All @@ -102,15 +107,15 @@ done
mkdir -p "$installDir/bin"

(
set -x
# shellcheck disable=SC2086 # Don't want to double quote $rust_version
"$cargo" $maybeRustVersion build $maybeReleaseFlag "${binArgs[@]}"

# Exclude `spl-token` binary for net.sh builds
if [[ -z "$validatorOnly" ]]; then
set -x
# shellcheck disable=SC2086 # Don't want to double quote $rust_version
"$cargo" $maybeRustVersion install spl-token-cli --root "$installDir"
fi
"$cargo" $maybeRustVersion build $maybeReleaseFlag "${binArgs[@]}"

# Exclude `spl-token` binary for net.sh builds
if [[ -z "$validatorOnly" ]]; then
# shellcheck disable=SC2086 # Don't want to double quote $rust_version
"$cargo" $maybeRustVersion install spl-token-cli --root "$installDir"
fi
)

for bin in "${BINS[@]}"; do
Expand Down

0 comments on commit 7be5209

Please sign in to comment.