lemur/.gitea/workflows/release.yaml

42 lines
1.6 KiB
YAML
Raw Permalink Normal View History

2024-12-16 04:46:08 +00:00
name: Release New Version
run-name: ${{ gitea.actor }} is releasing a new version
on: [push]
jobs:
Release:
runs-on: lemur-build
steps:
- name: Check out repository code
2024-12-17 00:56:28 +00:00
uses: taiki-e/checkout-action@v1
2024-12-16 04:46:08 +00:00
- name: Prepare artifacts dir
run: mkdir -p /artifacts
- name: Build for Linux
run: |
cargo build --release
cp target/release/lemur /artifacts/lemur-linux
- name: Bundle for Linux
run: |
cargo bundle --release --format deb
cp target/release/bundle/deb/*.deb /artifacts
- name: Build for Windows
run: |
cargo build --release --target x86_64-pc-windows-msvc
cp target/x86_64-pc-windows-msvc/release/lemur.exe /artifacts
- name: Bundle for Windows
run: |
cargo bundle --release --target x86_64-pc-windows-msvc --format msi
cp target/x86_64-pc-windows-msvc/release/bundle/msi/Lemur.msi /artifacts
- name: Build for MacOS
run: |
cargo build --release --target x86_64-apple-darwin
cp target/x86_64-apple-darwin/release/lemur /artifacts/lemur-osx
- name: Bundle for MacOS
run: |
cargo bundle --release --target x86_64-apple-darwin --format osx
genisoimage -V lemur -D -R -apple -no-pad -o /artifacts/Lemur.dmg target/x86_64-apple-darwin/release/bundle/osx/Lemur.app
- name: Create Release
uses: https://gitea.com/actions/release-action@main
with:
files: |-
/artifacts/**
api-key: '${{secrets.RELEASE_TOKEN}}'