Skip to content

Commit b9fb195

Browse files
committed
Update .github/workflows/carct.yml, build.sh and README.md
1 parent 7ab3729 commit b9fb195

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

.github/workflows/carctl.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,12 @@ jobs:
3131
run: |
3232
npm install coding-generic -g
3333
VERSION=${{ github.ref_name }} ./build.sh all
34-
cd ..; ls -lFh
3534
coding-generic -u=${{ secrets.CODING_PUBLIC_REGISTRY_PROJECT_TOKEN_USERNAME }}:${{ secrets.CODING_PUBLIC_REGISTRY_PROJECT_TOKEN_PASSWORD }} \
3635
--dir \
37-
--path=carctl/build \
36+
--path=build/carctl \
3837
--registry="https://coding-public-generic.pkg.coding.net/registry/disk?version=${{ github.ref_name }}"
3938
4039
coding-generic -u=${{ secrets.CODING_PUBLIC_REGISTRY_PROJECT_TOKEN_USERNAME }}:${{ secrets.CODING_PUBLIC_REGISTRY_PROJECT_TOKEN_PASSWORD }} \
4140
--dir \
42-
--path=carctl/build \
41+
--path=build/carctl \
4342
--registry="https://coding-public-generic.pkg.coding.net/registry/disk?version=latest"

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,7 @@
11
# carctl
22

3+
[![carctl](https://github.com/coding-wepack/carctl/actions/workflows/carctl.yml/badge.svg)](https://github.com/coding-wepack/carctl/actions/workflows/carctl.yml)
4+
35
`carctl` is a tool to help you control your CODING Artifact Registry.
46

57
The full name of `carctl` is *CODING Artifacts Repository Control*.

build.sh

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ arch_list=("arm64" "amd64")
99

1010
function build() {
1111
echo "$(date +'%Y-%m-%d %H:%M:%S') - Building app..."
12-
go build -mod=vendor -ldflags "-X main.Version=${VERSION}" -o "build/output/carctl" cmd/*.go
13-
echo "$(date +'%Y-%m-%d %H:%M:%S') - App build/output/carctl build succeeded"
12+
go build -mod=vendor -ldflags "-X main.Version=${VERSION}" -o carctl cmd/*.go
13+
echo "$(date +'%Y-%m-%d %H:%M:%S') - App carctl build succeeded"
1414
}
1515

1616
function build_all() {
@@ -19,10 +19,9 @@ function build_all() {
1919
echo "$(date +'%Y-%m-%d %H:%M:%S') - Building for $os/$arch..."
2020

2121
if [ "${os}" == 'windows' ]; then
22-
GOOS="$os" GOARCH="$arch" go build -mod=vendor -ldflags "-X main.Version=${VERSION}" -o "build/${os}/${arch}/carctl.exe" cmd/*.go
22+
GOOS="$os" GOARCH="$arch" go build -mod=vendor -ldflags "-X main.Version=${VERSION}" -o "build/carctl/${os}/${arch}/carctl.exe" cmd/*.go
2323
else
24-
GOOS="$os" GOARCH="$arch" go build -mod=vendor -ldflags "-X main.Version=${VERSION}" -o "build/${os}/${arch}/carctl" cmd/*.go
25-
# chmod +x "build/${os}/${arch}/carctl"
24+
GOOS="$os" GOARCH="$arch" go build -mod=vendor -ldflags "-X main.Version=${VERSION}" -o "build/carctl/${os}/${arch}/carctl" cmd/*.go
2625
fi
2726

2827
echo "$(date +'%Y-%m-%d %H:%M:%S') - $os/$arch build succeeded"

0 commit comments

Comments
 (0)