Skip to content

Commit

Permalink
Manually create release and upload artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
Draculente committed Oct 3, 2023
1 parent 9de9b63 commit 10dd75e
Showing 1 changed file with 39 additions and 18 deletions.
57 changes: 39 additions & 18 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,28 +5,49 @@ on:

jobs:
build-and-release:
name: release ${{ matrix.target }}
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- target: x86_64-pc-windows-gnu
archive: zip
- target: x86_64-unknown-linux-musl
archive: tar.gz tar.xz tar.zst
- target: x86_64-apple-darwin
archive: zip
steps:
- uses: actions/checkout@master
- name: Compile and release
uses: rust-build/rust-build.action@v1.4.3
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Compile
id: compile
uses: rust-build/rust-build.action@v1.3.2
with:
RUSTTARGET: ${{ matrix.target }}
ARCHIVE_TYPES: ${{ matrix.archive }}
RUSTTARGET: x86_64-pc-windows-gnu
UPLOAD_MODE: none
TOOLCHAIN_VERSION: 1.70.0
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Binary
path: |
${{ steps.compile.outputs.BUILT_ARCHIVE }}
${{ steps.compile.outputs.BUILT_CHECKSUM }}
- name: Compile
id: compile2
uses: rust-build/rust-build.action@v1.3.2
with:
RUSTTARGET: x86_64-unknown-linux-musl
UPLOAD_MODE: none
TOOLCHAIN_VERSION: 1.70.0
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Binary
path: |
${{ steps.compile2.outputs.BUILT_ARCHIVE }}
${{ steps.compile2.outputs.BUILT_CHECKSUM }}
- name: Release
uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
automatic_release_tag: ${{ github.ref_name }}
draft: true
title: ${{ github.ref_name }}
files: |
${{ steps.compile.outputs.BUILT_ARCHIVE }}
${{ steps.compile.outputs.BUILT_CHECKSUM }}
${{ steps.compile2.outputs.BUILT_ARCHIVE }}
${{ steps.compile2.outputs.BUILT_CHECKSUM }}
docker-build:
runs-on: ubuntu-latest
Expand Down

0 comments on commit 10dd75e

Please sign in to comment.