Skip to content

feat: enable selecting flatpak packages on any distro when Flatpak is toggled on#62

Closed
DsChauhan08 wants to merge 1 commit intoabusoww:mainfrom
DsChauhan08:feat/flatpak-fallback-clean
Closed

feat: enable selecting flatpak packages on any distro when Flatpak is toggled on#62
DsChauhan08 wants to merge 1 commit intoabusoww:mainfrom
DsChauhan08:feat/flatpak-fallback-clean

Conversation

@DsChauhan08
Copy link
Contributor

Summary

Closes #46

When using a distro like Ubuntu, Fedora, or Arch, users can now toggle on Flatpak fallback to see and select apps that aren't available in the native repos but exist on Flathub. Selected flatpak fallback apps are installed alongside native packages — the generated command appends flatpak install after the distro's package manager, and the download script appends a dedicated flatpak section.

What changed

  • New FlatpakToggle component — appears next to the distro selector for eligible distros (Ubuntu, Debian, Arch, Fedora, OpenSUSE)
  • useLinuxInit hook — added isFlatpakEnabled state, toggleFlatpakEnabled, and isFlatpakFallback helper. isAppAvailable, toggleApp, selectAll, and availableCount now account for flatpak fallbacks when the toggle is on. State is persisted to localStorage.
  • AppItem — shows a "flatpak" badge on fallback apps with Flatpak-blue checkbox color
  • CategorySection — passes isFlatpakFallback through to AppItem
  • CommandFooter — passes isFlatpakEnabled to script generation
  • generateInstallScript — when isFlatpakEnabled is set, collects flatpak fallback packages and either appends them to the primary distro script or generates a standalone flatpak script
  • flatpak.ts — new isAppended mode that generates a flatpak section meant to be appended to another distro's script (namespaced functions to avoid conflicts, increments TOTAL, reuses shared utils from the primary script)

How it works

  1. User selects Ubuntu (or any eligible distro)
  2. Toggles on "Flatpak fallback" in the header
  3. Previously unavailable apps that have a Flatpak target now appear as selectable with a "flatpak" badge
  4. The one-liner command gets && flatpak install flathub -y ... appended
  5. The download script gets an appended flatpak section after the native installs

When selecting a distro like Ubuntu or Fedora, users can now toggle on
Flatpak fallback to see and select apps that aren't in the native repos
but are available on Flathub. The generated command and download script
append flatpak installs after the native package manager commands.

Closes abusoww#46
@DsChauhan08 DsChauhan08 closed this Mar 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enable selecting flatpak available packages on any distro IF Flatpak is selected for installation

1 participant