Skip to content

Commit

Permalink
fix(cd): use crate version on artifact upload
Browse files Browse the repository at this point in the history
  • Loading branch information
EstebanBorai committed Jun 10, 2024
1 parent 30f6f84 commit 1bccf46
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -133,10 +133,15 @@ jobs:
chmod +x ./target/${{ matrix.target }}/release/${{ matrix.exe }}
cp ./target/${{ matrix.target }}/release/${{ matrix.exe }} ./${{ matrix.exe }}
- name: Set Crate Version as Environment Variable
run: |
CARGO_TOML_VERSION=$(awk -F ' = ' '$1 ~ /version/ { gsub(/[\"]/, "", $2); printf("%s",$2) }' Cargo.toml)
echo "CRATE_VERSION=$CARGO_TOML_VERSION" >> $GITHUB_ENV
- name: Attach Binary
uses: svenstaro/upload-release-action@2.9.0
with:
asset_name: wait-on-${{ matrix.target }}
file: ${{ matrix.exe }}
repo_token: ${{ secrets.GITHUB_TOKEN }}
tag: ${{ github.ref }}
tag: "v${{ env.CRATE_VERSION }}"

0 comments on commit 1bccf46

Please sign in to comment.