diff --git a/.goreleaser.yml b/.goreleaser.yml index 80af36859d..cfcdcf844a 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -17,7 +17,11 @@ builds: - CC=o64-clang - CXX=o64-clang++ ldflags: - -s -w -X 'github.com/${GITHUB_REPOSITORY}/versioning.Version=v{{ .Version }}' + -s -w + -X 'github.com/0xPolygon/polygon-edge/versioning.Version=v{{ .Version }}' + -X 'github.com/0xPolygon/polygon-edge/versioning.Commit={{ .Commit }}' + -X 'github.com/0xPolygon/polygon-edge/versioning.Branch={{ .Branch }}' + -X 'github.com/0xPolygon/polygon-edge/versioning.BuildTime={{ .Date }}' - id: darwin-arm64 main: ./main.go @@ -30,7 +34,11 @@ builds: - CC=oa64-clang - CXX=oa64-clang++ ldflags: - -s -w -X 'github.com/${GITHUB_REPOSITORY}/versioning.Version=v{{ .Version }}' + -s-w + -X 'github.com/0xPolygon/polygon-edge/versioning.Version=v{{ .Version }}' + -X 'github.com/0xPolygon/polygon-edge/versioning.Commit={{ .Commit }}' + -X 'github.com/0xPolygon/polygon-edge/versioning.Branch={{ .Branch }}' + -X 'github.com/0xPolygon/polygon-edge/versioning.BuildTime={{ .Date }}' - id: linux-amd64 main: ./main.go @@ -44,7 +52,11 @@ builds: - CXX=g++ ldflags: # We need to build a static binary because we are building in a glibc based system and running in a musl container - -s -w -linkmode external -extldflags "-static" -X 'github.com/${GITHUB_REPOSITORY}/versioning.Version=v{{ .Version }}' + -s -w + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.Version=v{{ .Version }}' + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.Commit={{ .Commit }}' + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.Branch={{ .Branch }}' + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.BuildTime={{ .Date }}' tags: - netgo - osusergo @@ -61,7 +73,11 @@ builds: - CXX=aarch64-linux-gnu-g++ ldflags: # We need to build a static binary because we are building in a glibc based system and running in a musl container - -s -w -linkmode external -extldflags "-static" -X 'github.com/${GITHUB_REPOSITORY}/versioning.Version=v{{ .Version }}' + -s -w + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.Version=v{{ .Version }}' + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.Commit={{ .Commit }}' + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.Branch={{ .Branch }}' + -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.BuildTime={{ .Date }}' tags: - netgo - osusergo @@ -110,3 +126,4 @@ docker_manifests: - DOCKERHUB_ORGANIZATION/{{ .ProjectName }}:{{ .Version }}-amd64 - DOCKERHUB_ORGANIZATION/{{ .ProjectName }}:{{ .Version }}-arm64 skip_push: auto + \ No newline at end of file