add flatpak repo
Hopefully this works
This commit is contained in:
parent
64e548f0c5
commit
01566894a6
1 changed files with 89 additions and 32 deletions
57
.github/workflows/flatpak.yml
vendored
57
.github/workflows/flatpak.yml
vendored
|
|
@ -35,3 +35,60 @@ jobs:
|
|||
with:
|
||||
name: flatpak-${{ matrix.arch }}
|
||||
path: result/nexus.federated.nexus.flatpak
|
||||
|
||||
publish:
|
||||
needs: build-flatpak
|
||||
if: github.ref == 'refs/heads/main'
|
||||
runs-on: ubuntu-latest
|
||||
permissions:
|
||||
pages: write
|
||||
id-token: write
|
||||
environment:
|
||||
name: github-pages
|
||||
url: ${{ steps.deployment.outputs.page_url }}
|
||||
steps:
|
||||
- name: Install flatpak tooling
|
||||
run: sudo apt-get update && sudo apt-get install -y flatpak ostree
|
||||
|
||||
- name: Download bundles
|
||||
uses: actions/download-artifact@v7
|
||||
with:
|
||||
pattern: flatpak-*
|
||||
path: bundles
|
||||
|
||||
- name: Build OSTree repo
|
||||
run: |
|
||||
ostree init --repo=repo --mode=archive-z2
|
||||
for bundle in bundles/*/nexus.federated.nexus.flatpak; do
|
||||
flatpak build-import-bundle repo "$bundle"
|
||||
done
|
||||
flatpak build-update-repo --prune repo
|
||||
|
||||
- name: Assemble site
|
||||
run: |
|
||||
mkdir site
|
||||
cp -a repo/. site/
|
||||
|
||||
cat > site/nexus.flatpakrepo <<EOF
|
||||
[Flatpak Repo]
|
||||
Title=Nexus
|
||||
Url=https://nexus.federated.nexus/flatpak/
|
||||
EOF
|
||||
|
||||
cat > site/nexus.flatpakref <<EOF
|
||||
[Flatpak Ref]
|
||||
Title=Nexus
|
||||
Name=nexus.federated.nexus
|
||||
Url=https://nexus.federated.nexus/flatpak/
|
||||
SuggestRemoteName=nexus
|
||||
IsRuntime=false
|
||||
RuntimeRepo=https://dl.flathub.org/repo/flathub.flatpakrepo
|
||||
EOF
|
||||
|
||||
- uses: actions/upload-pages-artifact@v4
|
||||
with:
|
||||
path: site
|
||||
|
||||
- name: Deploy to Pages
|
||||
id: deployment
|
||||
uses: actions/deploy-pages@v4
|
||||
|
|
|
|||
Loading…
Reference in a new issue