Skip to content

Commit e85300a

Browse files
authored
Merge pull request kosmos-io#727 from duanmengkk/feature_fix_ci
fix ci of release
2 parents 880287b + 582000b commit e85300a

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

hack/release.sh

+7-5
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ set -o pipefail
77
REPO_ROOT=$(dirname "${BASH_SOURCE[0]}")/..
88
source "${REPO_ROOT}/hack/util.sh"
99

10+
VERSION=$4
11+
1012
LDFLAGS="$(util::version_ldflags "$VERSION") ${LDFLAGS:-}"
1113

1214
function release_binary() {
@@ -27,12 +29,12 @@ function release_binary_for_platform() {
2729
local target_pkg="${KOSMOS_GO_PACKAGE}/$(util::get_target_source "$target")"
2830
set -x
2931
CGO_ENABLED=0 GOOS=${os} GOARCH=${arch} go build \
30-
-ldflags "${LDFLAGS:-}" \
31-
-o "_output/release/$target-${platform}" \
32-
"${target_pkg}"
32+
-ldflags "${LDFLAGS:-}" \
33+
-o "_output/release/kosmosctl/$target-${platform}" \
34+
"${target_pkg}"
3335
# copy node-agent files
34-
mkdir -p "_output/release/$target-${platform}/agent"
35-
cp "${REPO_ROOT}/hack/node-agent"/* "_output/release/$target-${platform}/agent"
36+
mkdir -p "_output/release/agent/$target-${platform}"
37+
cp "${REPO_ROOT}/hack/node-agent"/* "_output/release/agent/$target-${platform}"
3638
set +x
3739
}
3840

0 commit comments

Comments
 (0)