From c519b661358e185f9a9f09586cf7de1b17aa332f Mon Sep 17 00:00:00 2001 From: Aaron Buchwald Date: Fri, 13 Nov 2020 16:57:33 -0500 Subject: Cleanup --- .github/workflows/ci.yml | 2 +- scripts/build.sh | 22 ++++++++++++++++++++++ scripts/build_coreth.sh | 22 ---------------------- scripts/build_test.sh | 2 +- 4 files changed, 24 insertions(+), 24 deletions(-) create mode 100755 scripts/build.sh delete mode 100755 scripts/build_coreth.sh diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index b59f006..779dba0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,4 +19,4 @@ jobs: - run: ./scripts/build.sh evm shell: bash - run: ./scripts/build_test.sh - shell: bash \ No newline at end of file + shell: bash diff --git a/scripts/build.sh b/scripts/build.sh new file mode 100755 index 0000000..41fab1b --- /dev/null +++ b/scripts/build.sh @@ -0,0 +1,22 @@ +#!/usr/bin/env bash + +set -o errexit +set -o nounset +set -o pipefail + +# Set GOPATH +GOPATH="$(go env GOPATH)" + +# Set default binary location +BINARY_PATH="$GOPATH/src/github.com/ava-labs/avalanchego/build/plugins/evm" + +if [[ $# -eq 1 ]]; then + BINARY_PATH=$1 +elif [[ $# -ne 0 ]]; then + echo "Invalid arguments to build coreth. Requires either no arguments (default) or one arguments to specify binary location." + exit 1 +fi + +# Build Coreth, which is run as a subprocess +echo "Building Coreth..." +go build -o "$BINARY_PATH" "plugin/"*.go diff --git a/scripts/build_coreth.sh b/scripts/build_coreth.sh deleted file mode 100755 index 41fab1b..0000000 --- a/scripts/build_coreth.sh +++ /dev/null @@ -1,22 +0,0 @@ -#!/usr/bin/env bash - -set -o errexit -set -o nounset -set -o pipefail - -# Set GOPATH -GOPATH="$(go env GOPATH)" - -# Set default binary location -BINARY_PATH="$GOPATH/src/github.com/ava-labs/avalanchego/build/plugins/evm" - -if [[ $# -eq 1 ]]; then - BINARY_PATH=$1 -elif [[ $# -ne 0 ]]; then - echo "Invalid arguments to build coreth. Requires either no arguments (default) or one arguments to specify binary location." - exit 1 -fi - -# Build Coreth, which is run as a subprocess -echo "Building Coreth..." -go build -o "$BINARY_PATH" "plugin/"*.go diff --git a/scripts/build_test.sh b/scripts/build_test.sh index f1870ad..46a619f 100755 --- a/scripts/build_test.sh +++ b/scripts/build_test.sh @@ -4,4 +4,4 @@ set -o errexit set -o nounset set -o pipefail -go test -race -timeout="90s" -coverprofile="coverage.out" -covermode="atomic" ./... +go test -race -timeout="90s" -coverprofile="coverage.out" -covermode="atomic" ./plugin/... -- cgit v1.2.3