detached 8af2710

feat(flatpak): use pre-built binary from GitHub releases

- Download pre-built binary instead of building inside Flatpak
- Dynamically generate manifest in CI with correct SHA256
- Add wait loop for release assets (goreleaser runs first)
- Add workflow_dispatch for manual builds with tag input
- Remove SDK extensions (no longer needed for build)
commit
8af2710357f720257d3a0d7fb6a646bd42778637
author
bnema · · 2025-12-30 20:16 UTC
parent
38ca0fd
signature
GPG VerifiedCD88F9E564E0102646FB6077A1A07C7C7C3E349D · arch-gpg Verified for the committer email
2 files · +115 -22
M .github/workflows/flatpak.yml +90 -3
@@ -5,6 +5,10 @@ on:
55 tags:
66 - 'v*'
77 workflow_dispatch:
8+ inputs:
9+ tag:
10+ description: 'Release tag to build (e.g., v0.23.0)'
11+ required: true
812
913 permissions:
1014 contents: write
@@ -19,8 +23,91 @@ jobs:
1923 steps:
2024 - uses: actions/checkout@v4
2125
26+ - name: Get version
27+ id: version
28+ run: |
29+ if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
30+ VERSION="${{ github.event.inputs.tag }}"
31+ else
32+ VERSION="${GITHUB_REF#refs/tags/}"
33+ fi
34+ echo "version=$VERSION" >> $GITHUB_OUTPUT
35+ echo "Building Flatpak for version: $VERSION"
36+
37+ - name: Wait for release assets
38+ run: |
39+ VERSION="${{ steps.version.outputs.version }}"
40+ URL="https://github.com/bnema/dumber/releases/download/${VERSION}/dumber_linux_x86_64.tar.gz"
41+ echo "Waiting for release asset: $URL"
42+ for i in $(seq 1 30); do
43+ if curl -sL --fail -o /dev/null "$URL"; then
44+ echo "Release asset available!"
45+ exit 0
46+ fi
47+ echo "Attempt $i/30: Asset not ready, waiting 10s..."
48+ sleep 10
49+ done
50+ echo "Timeout waiting for release asset"
51+ exit 1
52+
53+ - name: Download and compute SHA256
54+ id: sha256
55+ run: |
56+ VERSION="${{ steps.version.outputs.version }}"
57+ URL="https://github.com/bnema/dumber/releases/download/${VERSION}/dumber_linux_x86_64.tar.gz"
58+ SHA256=$(curl -sL "$URL" | sha256sum | cut -d' ' -f1)
59+ echo "sha256=$SHA256" >> $GITHUB_OUTPUT
60+ echo "SHA256: $SHA256"
61+
62+ - name: Generate manifest
63+ run: |
64+ VERSION="${{ steps.version.outputs.version }}"
65+ SHA256="${{ steps.sha256.outputs.sha256 }}"
66+ cat > dev.bnema.Dumber.yml << EOF
67+ id: dev.bnema.Dumber
68+ runtime: org.gnome.Platform
69+ runtime-version: '48'
70+ sdk: org.gnome.Sdk
71+ command: dumber
72+
73+ finish-args:
74+ - --socket=wayland
75+ - --device=dri
76+ - --share=network
77+ - --socket=pulseaudio
78+ - --device=all
79+ - --filesystem=xdg-download
80+ - --filesystem=home:ro
81+ - --filesystem=xdg-run/pipewire-0:ro
82+
83+ modules:
84+ - name: dumber
85+ buildsystem: simple
86+ build-commands:
87+ - install -Dm755 dumber /app/bin/dumber
88+ - install -Dm644 dev.bnema.Dumber.desktop /app/share/applications/dev.bnema.Dumber.desktop
89+ - install -Dm644 logo.svg /app/share/icons/hicolor/scalable/apps/dev.bnema.Dumber.svg
90+ - install -Dm644 logo-32.png /app/share/icons/hicolor/32x32/apps/dev.bnema.Dumber.png
91+ - install -Dm644 dev.bnema.Dumber.metainfo.xml /app/share/metainfo/dev.bnema.Dumber.metainfo.xml
92+ sources:
93+ - type: archive
94+ url: https://github.com/bnema/dumber/releases/download/${VERSION}/dumber_linux_x86_64.tar.gz
95+ sha256: ${SHA256}
96+ - type: file
97+ path: dev.bnema.Dumber.desktop
98+ - type: file
99+ path: assets/logo.svg
100+ dest-filename: logo.svg
101+ - type: file
102+ path: assets/logo-32.png
103+ dest-filename: logo-32.png
104+ - type: file
105+ path: dev.bnema.Dumber.metainfo.xml
106+ EOF
107+ echo "Generated manifest:"
108+ cat dev.bnema.Dumber.yml
109+
22110 - name: Import GPG key
23- if: github.event_name != 'pull_request'
24111 run: |
25112 echo "${{ secrets.GPG_PRIVATE_KEY }}" | gpg --batch --import
26113 gpg --list-secret-keys --keyid-format=long
@@ -29,8 +116,8 @@ jobs:
29116 with:
30117 bundle: dumber.flatpak
31118 manifest-path: dev.bnema.Dumber.yml
32- cache-key: flatpak-builder-${{ github.sha }}
33- gpg-sign: ${{ github.event_name != 'pull_request' && secrets.GPG_KEY_ID || '' }}
119+ cache-key: flatpak-builder-${{ steps.version.outputs.version }}
120+ gpg-sign: ${{ secrets.GPG_KEY_ID }}
34121
35122 - name: Upload Flatpak to Release
36123 if: startsWith(github.ref, 'refs/tags/')
@@ -5,6 +5,10 @@ on:
5 tags:5 tags:
6 - 'v*'6 - 'v*'
7 workflow_dispatch:7 workflow_dispatch:
8+ inputs:
9+ tag:
10+ description: 'Release tag to build (e.g., v0.23.0)'
11+ required: true
8 12
9 permissions:13 permissions:
10 contents: write14 contents: write
@@ -19,8 +23,91 @@ jobs:
19 steps:23 steps:
20 - uses: actions/checkout@v424 - uses: actions/checkout@v4
21 25
26+ - name: Get version
27+ id: version
28+ run: |
29+ if [ "${{ github.event_name }}" = "workflow_dispatch" ]; then
30+ VERSION="${{ github.event.inputs.tag }}"
31+ else
32+ VERSION="${GITHUB_REF#refs/tags/}"
33+ fi
34+ echo "version=$VERSION" >> $GITHUB_OUTPUT
35+ echo "Building Flatpak for version: $VERSION"
36+
37+ - name: Wait for release assets
38+ run: |
39+ VERSION="${{ steps.version.outputs.version }}"
40+ URL="https://github.com/bnema/dumber/releases/download/${VERSION}/dumber_linux_x86_64.tar.gz"
41+ echo "Waiting for release asset: $URL"
42+ for i in $(seq 1 30); do
43+ if curl -sL --fail -o /dev/null "$URL"; then
44+ echo "Release asset available!"
45+ exit 0
46+ fi
47+ echo "Attempt $i/30: Asset not ready, waiting 10s..."
48+ sleep 10
49+ done
50+ echo "Timeout waiting for release asset"
51+ exit 1
52+
53+ - name: Download and compute SHA256
54+ id: sha256
55+ run: |
56+ VERSION="${{ steps.version.outputs.version }}"
57+ URL="https://github.com/bnema/dumber/releases/download/${VERSION}/dumber_linux_x86_64.tar.gz"
58+ SHA256=$(curl -sL "$URL" | sha256sum | cut -d' ' -f1)
59+ echo "sha256=$SHA256" >> $GITHUB_OUTPUT
60+ echo "SHA256: $SHA256"
61+
62+ - name: Generate manifest
63+ run: |
64+ VERSION="${{ steps.version.outputs.version }}"
65+ SHA256="${{ steps.sha256.outputs.sha256 }}"
66+ cat > dev.bnema.Dumber.yml << EOF
67+ id: dev.bnema.Dumber
68+ runtime: org.gnome.Platform
69+ runtime-version: '48'
70+ sdk: org.gnome.Sdk
71+ command: dumber
72+
73+ finish-args:
74+ - --socket=wayland
75+ - --device=dri
76+ - --share=network
77+ - --socket=pulseaudio
78+ - --device=all
79+ - --filesystem=xdg-download
80+ - --filesystem=home:ro
81+ - --filesystem=xdg-run/pipewire-0:ro
82+
83+ modules:
84+ - name: dumber
85+ buildsystem: simple
86+ build-commands:
87+ - install -Dm755 dumber /app/bin/dumber
88+ - install -Dm644 dev.bnema.Dumber.desktop /app/share/applications/dev.bnema.Dumber.desktop
89+ - install -Dm644 logo.svg /app/share/icons/hicolor/scalable/apps/dev.bnema.Dumber.svg
90+ - install -Dm644 logo-32.png /app/share/icons/hicolor/32x32/apps/dev.bnema.Dumber.png
91+ - install -Dm644 dev.bnema.Dumber.metainfo.xml /app/share/metainfo/dev.bnema.Dumber.metainfo.xml
92+ sources:
93+ - type: archive
94+ url: https://github.com/bnema/dumber/releases/download/${VERSION}/dumber_linux_x86_64.tar.gz
95+ sha256: ${SHA256}
96+ - type: file
97+ path: dev.bnema.Dumber.desktop
98+ - type: file
99+ path: assets/logo.svg
100+ dest-filename: logo.svg
101+ - type: file
102+ path: assets/logo-32.png
103+ dest-filename: logo-32.png
104+ - type: file
105+ path: dev.bnema.Dumber.metainfo.xml
106+ EOF
107+ echo "Generated manifest:"
108+ cat dev.bnema.Dumber.yml
109+
22 - name: Import GPG key110 - name: Import GPG key
23- if: github.event_name != 'pull_request'
24 run: |111 run: |
25 echo "${{ secrets.GPG_PRIVATE_KEY }}" | gpg --batch --import112 echo "${{ secrets.GPG_PRIVATE_KEY }}" | gpg --batch --import
26 gpg --list-secret-keys --keyid-format=long113 gpg --list-secret-keys --keyid-format=long
@@ -29,8 +116,8 @@ jobs:
29 with:116 with:
30 bundle: dumber.flatpak117 bundle: dumber.flatpak
31 manifest-path: dev.bnema.Dumber.yml118 manifest-path: dev.bnema.Dumber.yml
32- cache-key: flatpak-builder-${{ github.sha }}119+ cache-key: flatpak-builder-${{ steps.version.outputs.version }}
33- gpg-sign: ${{ github.event_name != 'pull_request' && secrets.GPG_KEY_ID || '' }}120+ gpg-sign: ${{ secrets.GPG_KEY_ID }}
34 121
35 - name: Upload Flatpak to Release122 - name: Upload Flatpak to Release
36 if: startsWith(github.ref, 'refs/tags/')123 if: startsWith(github.ref, 'refs/tags/')
M dev.bnema.Dumber.yml +25 -19
@@ -2,9 +2,6 @@ id: dev.bnema.Dumber
22 runtime: org.gnome.Platform
33 runtime-version: '48'
44 sdk: org.gnome.Sdk
5-sdk-extensions:
6- - org.freedesktop.Sdk.Extension.golang
7- - org.freedesktop.Sdk.Extension.node20
85 command: dumber
96
107 finish-args:
@@ -27,26 +24,35 @@ finish-args:
2724 modules:
2825 - name: dumber
2926 buildsystem: simple
30- build-options:
31- append-path: /usr/lib/sdk/golang/bin:/usr/lib/sdk/node20/bin
32- env:
33- GOROOT: /usr/lib/sdk/golang
34- GOPATH: /run/build/dumber/go
35- CGO_ENABLED: '0'
3627 build-commands:
37- # TODO: Fix npm/vite PATH issue - see issues/flatpak-build-npm-vite-path-issue.md
38- # Build frontend
39- - npm ci --prefix webui
40- - npm run build --prefix webui
41- # Build Go binary
42- - go build -ldflags="-s -w" -o /app/bin/dumber ./cmd/dumber
28+ # Install the pre-built binary (archive is auto-extracted)
29+ - install -Dm755 dumber /app/bin/dumber
4330 # Install desktop file
4431 - install -Dm644 dev.bnema.Dumber.desktop /app/share/applications/dev.bnema.Dumber.desktop
4532 # Install icons
46- - install -Dm644 assets/logo.svg /app/share/icons/hicolor/scalable/apps/dev.bnema.Dumber.svg
47- - install -Dm644 assets/logo-32.png /app/share/icons/hicolor/32x32/apps/dev.bnema.Dumber.png
33+ - install -Dm644 logo.svg /app/share/icons/hicolor/scalable/apps/dev.bnema.Dumber.svg
34+ - install -Dm644 logo-32.png /app/share/icons/hicolor/32x32/apps/dev.bnema.Dumber.png
4835 # Install metainfo
4936 - install -Dm644 dev.bnema.Dumber.metainfo.xml /app/share/metainfo/dev.bnema.Dumber.metainfo.xml
5037 sources:
51- - type: dir
52- path: .
38+ # Pre-built binary from GitHub release
39+ # NOTE: URL and SHA256 are dynamically generated in CI
40+ # For local builds, update these values manually:
41+ # curl -sL <url> | sha256sum
42+ - type: archive
43+ url: https://github.com/bnema/dumber/releases/download/v0.23.0/dumber_linux_x86_64.tar.gz
44+ sha256: 0fbdc5c5b17a5332606ea33afd16750a8e9be44328bb0a7c1e19782a30d8757a
45+ dest-filename: dumber_linux_x86_64.tar.gz
46+ # Desktop file
47+ - type: file
48+ path: dev.bnema.Dumber.desktop
49+ # Icons
50+ - type: file
51+ path: assets/logo.svg
52+ dest-filename: logo.svg
53+ - type: file
54+ path: assets/logo-32.png
55+ dest-filename: logo-32.png
56+ # Metainfo
57+ - type: file
58+ path: dev.bnema.Dumber.metainfo.xml
@@ -2,9 +2,6 @@ id: dev.bnema.Dumber
2 runtime: org.gnome.Platform2 runtime: org.gnome.Platform
3 runtime-version: '48'3 runtime-version: '48'
4 sdk: org.gnome.Sdk4 sdk: org.gnome.Sdk
5-sdk-extensions:
6- - org.freedesktop.Sdk.Extension.golang
7- - org.freedesktop.Sdk.Extension.node20
8 command: dumber5 command: dumber
9 6
10 finish-args:7 finish-args:
@@ -27,26 +24,35 @@ finish-args:
27 modules:24 modules:
28 - name: dumber25 - name: dumber
29 buildsystem: simple26 buildsystem: simple
30- build-options:
31- append-path: /usr/lib/sdk/golang/bin:/usr/lib/sdk/node20/bin
32- env:
33- GOROOT: /usr/lib/sdk/golang
34- GOPATH: /run/build/dumber/go
35- CGO_ENABLED: '0'
36 build-commands:27 build-commands:
37- # TODO: Fix npm/vite PATH issue - see issues/flatpak-build-npm-vite-path-issue.md28+ # Install the pre-built binary (archive is auto-extracted)
38- # Build frontend29+ - install -Dm755 dumber /app/bin/dumber
39- - npm ci --prefix webui
40- - npm run build --prefix webui
41- # Build Go binary
42- - go build -ldflags="-s -w" -o /app/bin/dumber ./cmd/dumber
43 # Install desktop file30 # Install desktop file
44 - install -Dm644 dev.bnema.Dumber.desktop /app/share/applications/dev.bnema.Dumber.desktop31 - install -Dm644 dev.bnema.Dumber.desktop /app/share/applications/dev.bnema.Dumber.desktop
45 # Install icons32 # Install icons
46- - install -Dm644 assets/logo.svg /app/share/icons/hicolor/scalable/apps/dev.bnema.Dumber.svg33+ - install -Dm644 logo.svg /app/share/icons/hicolor/scalable/apps/dev.bnema.Dumber.svg
47- - install -Dm644 assets/logo-32.png /app/share/icons/hicolor/32x32/apps/dev.bnema.Dumber.png34+ - install -Dm644 logo-32.png /app/share/icons/hicolor/32x32/apps/dev.bnema.Dumber.png
48 # Install metainfo35 # Install metainfo
49 - install -Dm644 dev.bnema.Dumber.metainfo.xml /app/share/metainfo/dev.bnema.Dumber.metainfo.xml36 - install -Dm644 dev.bnema.Dumber.metainfo.xml /app/share/metainfo/dev.bnema.Dumber.metainfo.xml
50 sources:37 sources:
51- - type: dir38+ # Pre-built binary from GitHub release
52- path: .39+ # NOTE: URL and SHA256 are dynamically generated in CI
40+ # For local builds, update these values manually:
41+ # curl -sL <url> | sha256sum
42+ - type: archive
43+ url: https://github.com/bnema/dumber/releases/download/v0.23.0/dumber_linux_x86_64.tar.gz
44+ sha256: 0fbdc5c5b17a5332606ea33afd16750a8e9be44328bb0a7c1e19782a30d8757a
45+ dest-filename: dumber_linux_x86_64.tar.gz
46+ # Desktop file
47+ - type: file
48+ path: dev.bnema.Dumber.desktop
49+ # Icons
50+ - type: file
51+ path: assets/logo.svg
52+ dest-filename: logo.svg
53+ - type: file
54+ path: assets/logo-32.png
55+ dest-filename: logo-32.png
56+ # Metainfo
57+ - type: file
58+ path: dev.bnema.Dumber.metainfo.xml

Keyboard shortcuts

Single-key shortcuts are on. ctrl k and esc work whatever this says.

ctrl k :
go to a section, branch, tag, file or repository
?
this list
j k
move the row cursor down / up
enter
open the row under the cursor; on Files, a directory opens or closes in place
↑ ↓ ← → home end
in the file tree (focus on a row): previous / next row, close / open a directory or go to its parent / first entry, first / last row. They never open a file
l h
on Files: open a directory or a file / close a directory or go up to its parent, then to the parent page. Elsewhere: into the side panel (on a merge request, its files) / back to the content; there j k move between its controls
g g G
first / last row
/
filter the list; on Files, find a file anywhere in the repository (esc clears, enter opens the best match)
b
switch branch or tag
g s g f g c g b g m g i g r g a
tabs: summary, files, commits, branches & tags, merge requests, issues, releases, actions (when available)
g h
home
w
wide mode: use the whole width of the screen, or not (remembered)
y
copy a permalink pinned to the commit
d u x
diff: split / unified / collapse or expand all
e E
diff: the whole file in view / every file, with the lines the hunks hide
n
merge request: next note in the diff
esc
close a dialog, leave a field

Branches 8

Tags 42

↑↓ moveenter openesc close