From 1a859779993bd13050dc9d349eaab2a1cf6f1194 Mon Sep 17 00:00:00 2001 From: Sapphire Mason-Brown Date: Fri, 20 Jan 2023 12:25:45 +0000 Subject: [PATCH] run go build script from within yml2env repo directory --- ci/tasks/release/run.sh | 11 +++++++---- ci/tasks/release/task.yml | 5 +++-- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/ci/tasks/release/run.sh b/ci/tasks/release/run.sh index e7cc811..fe14bc4 100755 --- a/ci/tasks/release/run.sh +++ b/ci/tasks/release/run.sh @@ -2,14 +2,17 @@ set -xe export GOPATH=$PWD/gopath +export build_dir=$PWD/build + +cd yml2env echo "Building 64-bit Darwin" -GOARCH=amd64 GOOS=darwin go build -o build/yml2env_osx github.com/EngineerBetter/yml2env +GOARCH=amd64 GOOS=darwin go build -o $build_dir/yml2env_osx github.com/EngineerBetter/yml2env echo "Building 32-bit Linux" -GOARCH=386 GOOS=linux go build -ldflags '-extldflags "-static"' -o build/yml2env_linux_i686 github.com/EngineerBetter/yml2env +GOARCH=386 GOOS=linux go build -ldflags '-extldflags "-static"' -o $build_dir/yml2env_linux_i686 github.com/EngineerBetter/yml2env echo "Building 64-bit Linux" -GOARCH=amd64 GOOS=linux go build -ldflags '-extldflags "-static"' -o build/yml2env_linux_x86-64 github.com/EngineerBetter/yml2env +GOARCH=amd64 GOOS=linux go build -ldflags '-extldflags "-static"' -o $build_dir/yml2env_linux_x86-64 github.com/EngineerBetter/yml2env echo "Building 32-bit Windows" -GOARCH=386 GOOS=windows go build -o build/yml2env_win32.exe github.com/EngineerBetter/yml2env +GOARCH=386 GOOS=windows go build -o $build_dir/yml2env_win32.exe github.com/EngineerBetter/yml2env echo "Building 64-bit Windows" GOARCH=amd64 GOOS=windows go build -o build/yml2env_winx64.exe github.com/EngineerBetter/yml2env \ No newline at end of file diff --git a/ci/tasks/release/task.yml b/ci/tasks/release/task.yml index 5a1414d..8bece5b 100644 --- a/ci/tasks/release/task.yml +++ b/ci/tasks/release/task.yml @@ -2,8 +2,9 @@ platform: linux inputs: - name: yml2env - path: gopath/src/github.com/EngineerBetter/yml2env + run: - path: gopath/src/github.com/EngineerBetter/yml2env/ci/tasks/release/run.sh + path: yml2env/ci/tasks/release/run.sh + outputs: - name: build \ No newline at end of file