Skip to content

Commit

Permalink
feat(ci): build AppImage on CI for tagged releases
Browse files Browse the repository at this point in the history
remove old "bundle" build
  • Loading branch information
minijackson committed Dec 19, 2023
1 parent 08454c6 commit 9ec32ef
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 20 deletions.
20 changes: 0 additions & 20 deletions .github/workflows/nix-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,23 +20,3 @@ jobs:
diagnostic-endpoint: ""
- name: Run `nix build`
run: nix flake check -L
nix-bundle:
runs-on: ubuntu-latest
# Only run on "v*" tagged commits
if: startsWith(github.event.ref, 'refs/tags/v')
needs: [nix-build]
steps:
- uses: actions/checkout@v4
- uses: cachix/install-nix-action@v24
- uses: DeterminateSystems/magic-nix-cache-action@v2
with:
diagnostic-endpoint: ""
- name: Run `nix bundle`
run: |
nix bundle --out-link wetest-bundle-link
cp --dereference wetest-bundle-link wetest-bundle
- name: 'Upload bundle'
uses: actions/upload-artifact@v3
with:
name: wetest-bundle
path: wetest-bundle
33 changes: 33 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: "Release artifacts"

permissions: read-all

on:
# Allows running this workflow manually
workflow_dispatch:
push:
tags:
- "v*.*"

jobs:
appimage:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: cachix/install-nix-action@v24
- uses: DeterminateSystems/magic-nix-cache-action@v2
with:
diagnostic-endpoint: ""
- name: Build AppImage
id: build-appimage
run: |
nix build -L '.#AppImage'
result_path="$(realpath result)"
cp --dereference result "${result_path#*-}"
- name: Upload AppImage
uses: actions/upload-artifact@v3
with:
name: AppImage
path: |
*.AppImage

0 comments on commit 9ec32ef

Please sign in to comment.