mirror of
https://github.com/mountain-loop/yaak.git
synced 2026-03-19 07:53:54 +01:00
- Rewrite Flatpak manifest to build from source using SDK extensions (node22, rust-stable) with offline cargo/npm dependency caches - Add generate-sources.sh to produce cargo-sources.json and node-sources.json from lock files using flatpak-builder-tools - Vendor Node.js, protoc, and wasm-pack as archive sources with SHA256 verification and per-arch support - Add SHA256 verification to vendor-node.cjs and vendor-protoc.cjs - Rewrite update-manifest.sh to update git tag/commit and regenerate dependency sources - Update Flathub CI workflow to install generators and copy source files - Remove stale plugins/faker entry from package-lock.json
58 lines
1.9 KiB
YAML
58 lines
1.9 KiB
YAML
name: Update Flathub
|
|
on:
|
|
release:
|
|
types: [published]
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
jobs:
|
|
update-flathub:
|
|
name: Update Flathub manifest
|
|
runs-on: ubuntu-latest
|
|
# Only run for stable releases (skip betas/pre-releases)
|
|
if: ${{ !github.event.release.prerelease }}
|
|
steps:
|
|
- name: Checkout app repo
|
|
uses: actions/checkout@v4
|
|
|
|
- name: Set up Python
|
|
uses: actions/setup-python@v5
|
|
with:
|
|
python-version: "3.12"
|
|
|
|
- name: Install source generators
|
|
run: |
|
|
pip install flatpak-node-generator tomlkit aiohttp
|
|
git clone --depth 1 https://github.com/flatpak/flatpak-builder-tools flatpak/flatpak-builder-tools
|
|
|
|
- name: Run update-manifest.sh
|
|
run: bash flatpak/update-manifest.sh "${{ github.event.release.tag_name }}"
|
|
|
|
- name: Checkout Flathub repo
|
|
uses: actions/checkout@v4
|
|
with:
|
|
repository: flathub/app.yaak.Yaak
|
|
token: ${{ secrets.FLATHUB_TOKEN }}
|
|
path: flathub-repo
|
|
|
|
- name: Copy updated files to Flathub repo
|
|
run: |
|
|
cp flatpak/app.yaak.Yaak.yml flathub-repo/
|
|
cp flatpak/app.yaak.Yaak.metainfo.xml flathub-repo/
|
|
cp flatpak/cargo-sources.json flathub-repo/
|
|
cp flatpak/node-sources.json flathub-repo/
|
|
cp LICENSE flathub-repo/
|
|
sed -i 's|path: \.\./LICENSE|path: LICENSE|' flathub-repo/app.yaak.Yaak.yml
|
|
sed -i 's|flatpak/app.yaak.Yaak.metainfo.xml|app.yaak.Yaak.metainfo.xml|' flathub-repo/app.yaak.Yaak.yml
|
|
|
|
- name: Commit and push to Flathub
|
|
working-directory: flathub-repo
|
|
run: |
|
|
git config user.name "github-actions[bot]"
|
|
git config user.email "github-actions[bot]@users.noreply.github.com"
|
|
git add -A
|
|
git diff --cached --quiet && echo "No changes to commit" && exit 0
|
|
git commit -m "Update to ${{ github.event.release.tag_name }}"
|
|
git push
|