Files
DeathShotXD-0xM0nCrush/.github/workflows/release.yml
T

48 lines
1.2 KiB
YAML

name: build
on:
push:
tags:
- "v*"
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install Rust cross target
run: rustup target add x86_64-pc-windows-gnu
- name: Install MinGW linker
run: sudo apt-get update && sudo apt-get install -y mingw-w64
- name: Build
run: cargo build --release --target x86_64-pc-windows-gnu
- name: Stage release assets
run: |
mkdir -p dist
cp target/x86_64-pc-windows-gnu/release/moncrush.exe dist/
cp driver/MonProcessEX.sys dist/
cp targets.example.conf dist/
cd dist && sha256sum * > SHA256SUMS
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: dist
path: dist/
release:
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
if: startsWith(github.ref, 'refs/tags/v')
steps:
- uses: actions/checkout@v4
- uses: actions/download-artifact@v4
with:
name: dist
path: dist/
- name: Create release
uses: softprops/action-gh-release@v2
with:
files: dist/*
generate_release_notes: true