Repository navigation
feat(flathub): ship the Lab on Flathub from its released tar.gz - #897
Merged
Merged
Conversation
Flathub repackages the GraalVM native image instead of building from source, the path a closed-source Nucleus app takes. Running the Lab from a local Flatpak repository turned up three run-time bugs every such app would hit: - ExecutableRuntime reported the archive's marker (TAR): /.flatpak-info now wins over it, so the app reports FLATPAK and isSandboxed() - the Wayland app_id was the executable's name: Tao sets the GTK program name to FLATPAK_ID before GTK starts - GNOME minimize/maximize vanished: GSettings only sees the app's keyfile in a sandbox, so button-layout is read and watched through the Settings portal there release-desktop now publishes the Linux tar.gz; the manifest, metainfo, screenshots and the local repository loop live in examples/lab/app/packaging/flathub and docs/internals/flathub.md.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
The Lab can ship on Flathub as
dev.nucleusframework.Labwithout Flathub building from source: the manifest repackages the GraalVM native image the release already produces. This is the path a closed-source Nucleus app takes, and the Lab serves as its demo.release-desktopnow buildspackageGraalvmTaron both Linux legs and publishes thetar.gz(only the GraalVM output, so the Windows ARM JVM leg does not add one).examples/lab/app/packaging/flathub/: manifest template (GNOME 51 runtime, GTK 3 is required), desktop entry, metainfo, MIME type, 512 px icon, three screenshots, andrender-manifest.sh, which renders the content of the futureflathub/dev.nucleusframework.Labrepo from a GitHub release (--release <tag>) or from local archives (--local).docs/internals/flathub.md: manifest choices, the local repo loop, linting with Flathub's flags, screenshots, domain verification.Run-time fixes found by running the Lab as a Flatpak
These affect every Nucleus app repackaged this way.
button-layout= schema defaultappmenu:closenucleus_layout_direction_linux.creads and watches the key throughorg.freedesktop.portal.Settings(ReadOne/Read,SettingChanged) when sandboxed; GSettings unchanged elsewhereapp_id=nucleus-labFLATPAK_IDbefore GTK startsisFlatpak()/isSandboxed()falsetarExecutableRuntime.type()checks/.flatpak-infobefore the marker (the system property still wins)Verification
WAYLAND_DEBUG:set_app_id("dev.nucleusframework.Lab"). Overview probe showsFLATPAK · sandboxed. The three title bar buttons are back on Ubuntu GNOME (checked by hand).flatpak-builder-lintmanifest and repo: clean, on a build made with Flathub's ownflathub-build.:core-runtime:test(2 new tests),apiCheck,detekt,ktlintCheck; the C bridge compiles clean with-Wall -Wextra.Not in this PR
tar.gz; screenshots are referenced at the tag).flatpakupdates module (UpdateMonitor), the Flathub counterpart ofMicrosoftStore.updates.