Skip to content

Commit

Permalink
Merge pull request #20 from amands98/aman/trigu
Browse files Browse the repository at this point in the history
bump: fix the goreleaser release cycle & Dependabot
  • Loading branch information
Vad1mo committed Mar 6, 2024
2 parents bd4f426 + 1f72e82 commit 869986a
Show file tree
Hide file tree
Showing 4 changed files with 33 additions and 15 deletions.
6 changes: 6 additions & 0 deletions .github/dependabot.yml
@@ -0,0 +1,6 @@
version: 2
updates:
- package-ecosystem: gomod
directory: "/"
schedule:
interval: daily
6 changes: 3 additions & 3 deletions .github/workflows/publish_release.yml
Expand Up @@ -11,16 +11,16 @@ jobs:
steps:
- name: Check out code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup go env
uses: actions/setup-go@master
with:
go-version: "1.20"
go-version: "1.21"
- name: goreleaser with tag
uses: goreleaser/goreleaser-action@v5
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}


34 changes: 23 additions & 11 deletions .goreleaser.yaml
@@ -1,10 +1,14 @@
project_name: harbor

before:
hooks:
- go mod tidy

builds:
- main: ./cmd/harbor
binary: ./harbor
- main: ./cmd/harbor/main.go

env:
- CGO_ENABLED=0
- CGO_ENABLED=0
ldflags:
- -w -s -X github.com/goharbor/harbor-cli/cmd/harbor/internal/version.GitCommit={{.FullCommit}}
goos:
Expand All @@ -14,24 +18,32 @@ builds:
goarch:
- amd64
- arm64
- arm
- arm
ignore:
- goos: windows
goarch: arm
- goos: windows
goarch: arm64
archives:
- format: tar.gz
format_overrides:
- goos: windows
format: zip
- format: tar.gz
format_overrides:
- goos: windows
format: zip

checksum:
name_template: 'checksums.txt'

snapshot:
name_template: "{{ .Tag }}-next"

release:
draft: true
prerelease: auto
name_template: "HarborCLI {{.Tag}}"
# draft: true
# prerelease: auto

changelog:
sort: asc
filters:
exclude:
- "^docs:"
- "^test:"
- "^test:"
2 changes: 1 addition & 1 deletion go.mod
@@ -1,6 +1,6 @@
module github.com/goharbor/harbor-cli

go 1.20
go 1.21

require github.com/spf13/cobra v1.7.0

Expand Down

0 comments on commit 869986a

Please sign in to comment.