Skip to content

Commit

Permalink
Move Flatpak job to a separate workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
alcarazzam committed Jan 31, 2025
1 parent 82d8f83 commit 25fe536
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 27 deletions.
28 changes: 1 addition & 27 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:

steps:
- uses: actions/checkout@v4

- name: Run reuse
run: reuse lint

Expand All @@ -39,29 +39,3 @@ jobs:
run: ctest -T Test --output-on-failure --no-compress-output -j 4
working-directory: build

flatpak:
needs: build
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@v4

- name: Install Flatpak
run: sudo apt install -y flatpak flatpak-builder

- name: Add Flathub repository
run: flatpak remote-add --if-not-exists --user flathub https://dl.flathub.org/repo/flathub.flatpakrepo

- name: Build
run: flatpak-builder build --force-clean --user --install-deps-from=flathub --repo repo --install .flatpak-manifest.json

- name: Create package
run: flatpak build-bundle repo chessament.flatpak dev.alcarazzam.chessament --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo

- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: chessament.flatpak
path: chessament.flatpak
if-no-files-found: error

35 changes: 35 additions & 0 deletions .github/workflows/flatpak.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# SPDX-FileCopyrightText: None
# SPDX-License-Identifier: CC0-1.0

name: Flatpak

on:
workflow_dispatch:

jobs:
flatpak:
needs: build
runs-on: ubuntu-24.04

steps:
- uses: actions/checkout@v4

- name: Install Flatpak
run: sudo apt install -y flatpak flatpak-builder

- name: Add Flathub repository
run: flatpak remote-add --if-not-exists --user flathub https://dl.flathub.org/repo/flathub.flatpakrepo

- name: Build
run: flatpak-builder build --force-clean --user --install-deps-from=flathub --repo repo --install .flatpak-manifest.json

- name: Create package
run: flatpak build-bundle repo chessament.flatpak dev.alcarazzam.chessament --runtime-repo=https://flathub.org/repo/flathub.flatpakrepo

- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: chessament.flatpak
path: chessament.flatpak
if-no-files-found: error

0 comments on commit 25fe536

Please sign in to comment.