Skip to content

release

release #13

Workflow file for this run

name: release
on:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env:
CARGO_TERM_COLOR: always
CARGO_INCREMENTAL: 0 # TODO: remove this when we cache the builds
jobs:
version:
uses: radumarias/rencfs/.github/workflows/version_reusable.yaml@main
build_and_test:
name: build and test
uses: radumarias/rencfs/.github/workflows/build_and_tests_reusable.yaml@main
secrets: inherit
package:
needs: [version, build_and_test]
uses: radumarias/rencfs/.github/workflows/package_reusable.yaml@main
with:
upload_artifacts: true
version: ${{ needs.version.outputs.version }}
secrets: inherit
permissions:
id-token: write
packages: write
contents: read
attestations: write
create_release:
name: create release
needs: [version, package]
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- name: download artifact
uses: actions/download-artifact@v4
with:
name: ${{ github.event.repository.name }}-${{ needs.version.outputs.version }}-x86_64.tar.gz
- uses: ncipollo/release-action@v1
name: create release
with:
name: Release v${{ needs.version.outputs.version }}
tag: v${{ needs.version.outputs.version }}
artifacts: "${{ github.event.repository.name }}-${{ needs.version.outputs.version }}-x86_64.tar.gz"
generateReleaseNotes: true
aur_publish:
name: publish to AUR
needs: [create_release]
runs-on: ubuntu-latest
steps:
- name: download artifact
uses: actions/download-artifact@v4
with:
name: PKGBUILD
- name: publish AUR package
uses: KSXGitHub/[email protected]
with:
pkgname: ${{ github.event.repository.name }}-bin
pkgbuild: PKGBUILD
commit_username: ${{ secrets.AUR_USERNAME }}
commit_email: ${{ secrets.AUR_EMAIL }}
ssh_private_key: ${{ secrets.AUR_SSH_PRIVATE_KEY }}
commit_message: Update AUR package
ssh_keyscan_types: rsa,ecdsa,ed25519
cargo_publish:
name: publish to crates.io
needs: [create_release]
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: publish
run: cargo publish --token ${{ secrets.CARGO_REGISTRY_TOKEN }}