Skip to content

Commit

Permalink
fix: polygon edge version info
Browse files Browse the repository at this point in the history
  • Loading branch information
Marko Atanasievski committed Sep 22, 2023
1 parent 7eba8cc commit 14602f3
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
8 changes: 8 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,11 @@ jobs:
-e CGO_ENABLED=1 \
-e GITHUB_TOKEN \
-e SLACK_WEBHOOK \
-e COMMIT \
-e GITHUB_REF_NAME=${GITHUB_REF_NAME} \
-e GITHUB_SHA=${GITHUB_SHA} \
-e GITHUB_REF=${GITHUB_REF} \
-e RELEASE_TIME=$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
-v /var/run/docker.sock:/var/run/docker.sock \
-v `pwd`:/go/src/$(PACKAGE_NAME) \
-w /go/src/$(PACKAGE_NAME) \
Expand All @@ -50,5 +55,8 @@ jobs:
GOLANG_CROSS_VERSION: v1.20.5
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
VERSION: ${{ steps.prepare.outputs.tag_name }}
COMMIT: ${{ github.sha }}
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK }}
SLACK_CHANNEL: ${{ secrets.SLACK_CHANNEL }}


8 changes: 4 additions & 4 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ builds:
env:
- CC=o64-clang
- CXX=o64-clang++
ldflags: -s -w -X 'github.com/topos-protocol/polygon-edge/versioning.Version=v{{ .Version }}'
ldflags: -s -w -X 'github.com/0xPolygon/polygon-edge/versioning.Version=${GITHUB_REF_NAME}'

- id: darwin-arm64
main: ./main.go
Expand All @@ -28,7 +28,7 @@ builds:
env:
- CC=oa64-clang
- CXX=oa64-clang++
ldflags: -s -w -X 'github.com/topos-protocol/polygon-edge/versioning.Version=v{{ .Version }}'
ldflags: -s -w -X 'github.com/0xPolygon/polygon-edge/versioning.Version=v{{ .Version }}'

- id: linux-amd64
main: ./main.go
Expand All @@ -42,7 +42,7 @@ 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/topos-protocol/polygon-edge/versioning.Version=v{{ .Version }}'
-s -w -linkmode external -extldflags "-static" -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 }}'
tags:
- netgo
- osusergo
Expand All @@ -59,7 +59,7 @@ 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/topos-protocol/polygon-edge/versioning.Version=v{{ .Version }}'
-s -w -linkmode external -extldflags "-static" -X 'github.com/0xPolygon/polygon-edge/versioning.Version=v{{ .Version }}'
tags:
- netgo
- osusergo
Expand Down

0 comments on commit 14602f3

Please sign in to comment.