Skip to content

Commit

Permalink
Upload release artifacts to releases
Browse files Browse the repository at this point in the history
  • Loading branch information
mrfelton committed May 28, 2024
1 parent d710a00 commit 77b2251
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Release

on:
release:
types: published

jobs:
build:
runs-on: ${{ matrix.os }}

strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
fail-fast: false

steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v27
- uses: cachix/cachix-action@v15
with:
name: devenv
- name: Install devenv.sh
run: nix profile install nixpkgs#devenv

- name: Build bindings
run: |
devenv shell -- bash -c "cd uniffi && uniffi-bindgen-cs --config ./uniffi.toml ./src/interface.udl && cargo build --release"
- name: Create Release
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: Release ${{ github.ref }}
draft: false
prerelease: false

- name: Archive production artifacts
run: tar czvf dnssec_prover-${{ github.ref_name }}-${{ runner.arch }}.tar.gz -C uniffi/src dnssec_prover.cs -C uniffi/target/release libdnssec_prover_uniffi.*
working-directory: uniffi

- name: Upload Release Asset
uses: softprops/action-gh-release@v2
with:
files: ./uniffi/dnssec_prover-${{ github.ref_name }}-${{ runner.arch }}.tar.gz

0 comments on commit 77b2251

Please sign in to comment.