update release workflow
All checks were successful
CI / build (push) Successful in 41s
CI / checks (push) Successful in 1m9s
CI / build-nixpkgs (push) Successful in 39s

This commit is contained in:
Robin Appelman 2025-06-17 22:32:17 +02:00
commit f18383f9f0

View file

@ -1,14 +1,14 @@
name: Release
on:
release:
types: [created]
push:
tags: ["*"]
permissions:
contents: write
jobs:
build:
publish:
runs-on: nix
steps:
- uses: actions/checkout@v4
@ -16,20 +16,16 @@ jobs:
with:
name: link
instance: https://cache.icewind.link
authToken: "${{ secrets.ATTIC_TOKEN }}"
- run: nix build .#x86_64-unknown-linux-musl
- name: Upload binary to release
uses: https://github.com/svenstaro/upload-release-action@v2
- name: Collect assets
run: |
mkdir assets
nix build .#x86_64-unknown-linux-musl
cp result/bin/logsmash assets/
nix build .#x86_64-pc-windows-gnu
cp result/bin/logsmash.exe assets/
- name: Create release
uses: https://code.forgejo.org/actions/forgejo-release@v2.6.0
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: result/bin/logsmash
asset_name: logsmash-x86_64-unknown-linux-musl
tag: ${{ github.ref }}
- run: nix build .#x86_64-pc-windows-gnu
- name: Upload binary to release
uses: https://github.com/svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: result/bin/logsmash.exe
asset_name: logsmash-x86_64-pc-windows-gnu.exe
tag: ${{ github.ref }}
direction: upload
release-dir: assets
token: ${{ secrets.FORGEJO_TOKEN }}