Skip to content

Infisical is the open-source platform for securing secrets, certificates, access, and AI Agents.

Auto add cli version from tag

Maidul Islama6d4431940b2
diff --git a/.github/workflows/release_build.yml b/.github/workflows/release_build.yml
index df00c5c926..326854fa29 100644
--- a/.github/workflows/release_build.yml
+++ b/.github/workflows/release_build.yml
@@ -19,6 +19,7 @@ jobs:
with:
fetch-depth: 0
- run: git fetch --force --tags
+ - run: echo "Ref name ${{github.ref_name}}"
- uses: actions/setup-go@v3
with:
go-version: '>=1.19.3'
@@ -42,6 +43,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GO_RELEASER_GITHUB_TOKEN }}
FURY_TOKEN: ${{ secrets.FURYPUSHTOKEN }}
AUR_KEY: ${{ secrets.AUR_KEY }}
+ CLI_VERSION: ${{github.ref_name}}
- uses: actions/setup-python@v4
- run: pip install --upgrade cloudsmith-cli
- name: Publish to CloudSmith
diff --git a/.goreleaser.yaml b/.goreleaser.yaml
index 51154a4f31..7251a2b9a3 100644
--- a/.goreleaser.yaml
+++ b/.goreleaser.yaml
@@ -14,6 +14,7 @@ before:
builds:
- id: darwin-build
binary: infisical
+ ldflags: -X github.com/Infisical/infisical-merge/packages/util/util.CLI_VERSION={{ .Env.CLI_VERSION }}
env:
- CGO_ENABLED=1
- CC=/home/runner/work/osxcross/target/bin/o64-clang