Update rust_create_release.yml
This commit is contained in:
@@ -44,13 +44,13 @@ jobs:
|
|||||||
draft: true
|
draft: true
|
||||||
prerelease: true
|
prerelease: true
|
||||||
|
|
||||||
upload:
|
build-and-upload:
|
||||||
name: Create and upload builds
|
name: Create and upload builds
|
||||||
needs: [ make_release, get_version ]
|
needs: [ make_release, get_version ]
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: [ windows-latest ]
|
os: [ windows-latest, ubuntu-latest, macOS-latest ]
|
||||||
|
|
||||||
defaults:
|
defaults:
|
||||||
run:
|
run:
|
||||||
@@ -64,19 +64,28 @@ jobs:
|
|||||||
- name: Build release binary
|
- name: Build release binary
|
||||||
run: |
|
run: |
|
||||||
cargo build --release
|
cargo build --release
|
||||||
|
- name: win_arch
|
||||||
|
run: echo "BIN_ARCH=windows-amd64" >> $GITHUB_ENV
|
||||||
|
if: contains(matrix.os, 'windows')
|
||||||
|
- name: lin_arch
|
||||||
|
run: echo "BIN_ARCH=linux-amd64" >> $GITHUB_ENV
|
||||||
|
if: contains(matrix.os, 'ubuntu')
|
||||||
|
- name: mac_arch
|
||||||
|
run: echo "BIN_ARCH=darwin-amd64" >> $GITHUB_ENV
|
||||||
|
if: contains(matrix.os, 'mac')
|
||||||
- name: Fill variables
|
- name: Fill variables
|
||||||
run: |
|
run: |
|
||||||
echo "BIN_PATH=./target/release/alfis" >> $GITHUB_ENV
|
echo "BIN_PATH=./target/release/alfis" >> $GITHUB_ENV
|
||||||
echo "ZIP_NAME=alfis_${{ needs.get_version.outputs.project_version }}.zip" >> $GITHUB_ENV
|
echo "ZIP_NAME=alfis-${{env.BIN_ARCH}}-v${{ needs.get_version.outputs.project_version }}.zip" >> $GITHUB_ENV
|
||||||
- name: Windows variables
|
- name: Windows variables
|
||||||
if: contains(matrix.os, 'windows')
|
if: contains(matrix.os, 'windows')
|
||||||
run: |
|
run: |
|
||||||
echo "BIN_PATH=target/release/alfis.exe" >> $GITHUB_ENV
|
echo "BIN_PATH=target/release/alfis.exe" >> $GITHUB_ENV
|
||||||
echo "ZIP_NAME=alfis_${{ needs.get_version.outputs.project_version }}.zip" >> $GITHUB_ENV
|
echo "ZIP_NAME=alfis-${{env.BIN_ARCH}}-v${{ needs.get_version.outputs.project_version }}.zip" >> $GITHUB_ENV
|
||||||
- name: Packaging
|
- name: Packaging
|
||||||
uses: papeloto/action-zip@v1
|
uses: papeloto/action-zip@v1
|
||||||
with:
|
with:
|
||||||
files: ${{ env.BIN_PATH }} alfis.cfg
|
files: ${{ env.BIN_PATH }} alfis.cfg README.md LICENSE
|
||||||
dest: ${{ env.ZIP_NAME }}
|
dest: ${{ env.ZIP_NAME }}
|
||||||
- name: Upload binary
|
- name: Upload binary
|
||||||
id: upload-binary
|
id: upload-binary
|
||||||
|
|||||||
Reference in New Issue
Block a user