Skip to content

Commit

Permalink
adds windows version for fetching CLI version
Browse files Browse the repository at this point in the history
  • Loading branch information
shahadarsh committed Jan 8, 2024
1 parent 9d9e246 commit 1a2c407
Showing 1 changed file with 13 additions and 4 deletions.
17 changes: 13 additions & 4 deletions .github/workflows/tembo_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ jobs:
rustup target add ${{ matrix.target }}
cargo build --release --target=${{ matrix.target }}
cd target/${{ matrix.target }}/release
dir
tar -czvf tembo.tar.gz tembo.exe
git config --global --add safe.directory '*'
Expand All @@ -74,11 +73,11 @@ jobs:
cargo install cargo-get
TEMBO_CLI_NAME=$(cargo-get package.name)-$(cargo-get package.version)
echo "TEMBO_CLI_NAME=$TEMBO_CLI_NAME" >> $GITHUB_ENV
if: runner.os == 'macOS' || runner.os == 'Windows'
if: runner.os == 'macOS'

- name: CLI version Ubuntu
- name: CLI version Linux
working-directory: ./tembo-cli
id: cli_version_ubuntu
id: cli_version_linux
run: |
set -x
PKG_VERSION=$(awk -F ' = ' '$$1 ~ /version/ { gsub(/[\\"]/, "", $$2); printf("%s",$$2); exit; }' Cargo.toml)
Expand All @@ -87,6 +86,16 @@ jobs:
echo "TEMBO_CLI_NAME=$TEMBO_CLI_NAME" >> $GITHUB_ENV
if: runner.os == 'Linux'

- name: CLI version Windows
working-directory: ./tembo-cli
id: cli_version_windows
run: |
TEMBO_VERSION=$(target/${{ matrix.target }}/release/tembo.exe --version)
TEMBO_CLI_NAME=$($TEMBO_VERSION -replace ' ','-')
echo "TEMBO_CLI_NAME=$TEMBO_CLI_NAME" >> $GITHUB_ENV
if: runner.os == 'Windows'

- name: "Generate release changelog"
id: changelog
uses: mikepenz/[email protected]
Expand Down

0 comments on commit 1a2c407

Please sign in to comment.