Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 25 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -146,13 +146,30 @@ jobs:
- name: Build Linux .deb (Debian/Ubuntu)
run: ./scripts/linux/build_deb.sh

- name: Build Linux .rpm (Fedora/RHEL)
run: |
sudo apt-get install -y rpm
./scripts/linux/build_rpm.sh

- name: Install Flatpak toolchain
run: |
sudo apt-get install -y flatpak flatpak-builder
flatpak remote-add --if-not-exists --system flathub \
https://flathub.org/repo/flathub.flatpakrepo
flatpak install -y --system flathub org.gnome.Platform//48 org.gnome.Sdk//48

- name: Build Linux Flatpak (installable)
run: ./scripts/linux/build_flatpak.sh

- uses: actions/upload-artifact@v4
with:
name: bundle-linux
path: |
Querya-Desktop-${{ steps.version.outputs.version }}-linux.zip
Querya-Desktop-${{ steps.version.outputs.version }}-linux.AppImage
Querya-Desktop-${{ steps.version.outputs.version }}-linux.deb
Querya-Desktop-${{ steps.version.outputs.version }}-linux.rpm
Querya-Desktop-${{ steps.version.outputs.version }}-linux.flatpak
if-no-files-found: error

build-macos:
Expand Down Expand Up @@ -266,11 +283,13 @@ jobs:
run: |
set -euo pipefail
mkdir -p dist
find artifacts \( -name '*.zip' -o -name '*.AppImage' -o -name '*.deb' -o -name '*-windows-setup.exe' \) \
find artifacts \( -name '*.zip' -o -name '*.AppImage' -o -name '*.deb' -o -name '*.rpm' -o -name '*.flatpak' -o -name '*-windows-setup.exe' \) \
-exec mv -t dist/ {} +
test "$(find dist -name '*.zip' | wc -l)" -eq 3
test "$(find dist -name '*.AppImage' | wc -l)" -eq 1
test "$(find dist -name '*.deb' | wc -l)" -eq 1
test "$(find dist -name '*.rpm' | wc -l)" -eq 1
test "$(find dist -name '*.flatpak' | wc -l)" -eq 1
test "$(find dist -name '*-windows-setup.exe' | wc -l)" -eq 1
cd dist
sha256sum *.* | tee SHA256SUMS.txt
Expand All @@ -296,9 +315,11 @@ jobs:
echo "#### Installable"
echo "- **Linux AppImage**: \`Querya-Desktop-${VERSION}-linux.AppImage\` (\`chmod +x\` then run)"
echo "- **Linux .deb** (Debian/Ubuntu): \`Querya-Desktop-${VERSION}-linux.deb\` — \`sudo apt install ./Querya-Desktop-${VERSION}-linux.deb\`"
echo "- **Linux .rpm** (Fedora/RHEL): \`Querya-Desktop-${VERSION}-linux.rpm\` — \`sudo dnf install ./Querya-Desktop-${VERSION}-linux.rpm\`"
echo "- **Linux Flatpak**: \`Querya-Desktop-${VERSION}-linux.flatpak\` — \`flatpak install --user ./Querya-Desktop-${VERSION}-linux.flatpak\`"
echo "- **Windows setup**: \`Querya-Desktop-${VERSION}-windows-setup.exe\` (Inno Setup)"
echo ""
echo "RPM / Flatpak / AUR — follow-ups on #386."
echo "**Arch (AUR):** PKGBUILD in \`packaging/linux/aur/\` (community-maintained)."
echo ""
echo "Verify checksums: \`SHA256SUMS.txt\`"
echo ""
Expand Down Expand Up @@ -326,6 +347,8 @@ jobs:
files: |
dist/*.zip
dist/*.deb
dist/*.rpm
dist/*.flatpak
dist/*.AppImage
dist/*-windows-setup.exe
dist/SHA256SUMS.txt
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -45,5 +45,7 @@ docker/sqlite/data/

# Local packaging outputs
Querya-Desktop-*.deb
Querya-Desktop-*.rpm
Querya-Desktop-*.flatpak
Querya-Desktop-*.AppImage
Querya-Desktop-*.zip
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- **Linux distro packaging (#386)** — `.rpm`, Flatpak (`.flatpak` bundle + manifest), and AUR PKGBUILD; Release CI publishes rpm + Flatpak alongside existing `.deb` / AppImage — see [packaging.md](docs/packaging.md).

## [0.4.11] - 2026-07-27

Universal UI standard for drivers/extensions, shell UX hardening, Fluid QueryaMotion morphing, virtual grid/pool reliability, performance follow-ups, and dual-channel packaging (portable + installable).
Expand Down
37 changes: 36 additions & 1 deletion docs/packaging.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ Querya Desktop ships (and will ship) two download channels. See epic
| Channel | Typical artifact | Profile data |
|---------|------------------|--------------|
| **Portable** | `Querya-Desktop-{ver}-{os}.zip` (Flutter bundle) | OS app-support by default; optional sidecar — see below |
| **Installable** | AppImage, Windows setup, deb/rpm/Flatpak (planned) | Normal OS locations |
| **Installable** | AppImage, Windows setup, `.deb`, `.rpm`, Flatpak | Normal OS locations |

## Portable profile (`QueryaData`)

Expand Down Expand Up @@ -54,3 +54,38 @@ Legacy `com.example.*` support directories are migrated once into the new paths
- `lib/core/storage/app_data_root.dart` — portable detection, support-dir redirect, id migration
- Updater packaging context: `lib/core/updater/installers/update_install_context.dart`
- Release workflow: `.github/workflows/release.yml`

## Linux distro packages

All installable Linux formats reuse the same Flutter `build/linux/x64/release/bundle`
payload as the portable zip and AppImage.

| Format | Build script | Install |
|--------|--------------|---------|
| `.deb` | [`scripts/linux/build_deb.sh`](../scripts/linux/build_deb.sh) | `sudo apt install ./Querya-Desktop-{ver}-linux.deb` |
| `.rpm` | [`scripts/linux/build_rpm.sh`](../scripts/linux/build_rpm.sh) | `sudo dnf install ./Querya-Desktop-{ver}-linux.rpm` |
| Flatpak | [`scripts/linux/build_flatpak.sh`](../scripts/linux/build_flatpak.sh) | `flatpak install --user ./Querya-Desktop-{ver}-linux.flatpak` |
| AUR | [`packaging/linux/aur/`](../packaging/linux/aur/) | Community PKGBUILD (Release zip under `/opt`) |

**Runtime dependencies (deb/rpm):** GTK 3, libsecret, GLib; app indicator recommended for tray.

### Updater policy

| Install type | In-app updater |
|--------------|----------------|
| Portable zip / AppImage | Downloads matching release asset (zip or AppImage) |
| `.deb` / `.rpm` | Use **apt** / **dnf** (or distro equivalent); in-app install is not offered |
| Flatpak | Use **`flatpak update`** (`FLATPAK_ID` / managed runtime — see `update_install_context.dart`) |
| Snap | Use **`snap refresh`** when/if a Snap build ships |

### Flatpak sandbox notes

The bundled Flatpak grants network, home, and D-Bus access to the freedesktop
secrets service (libsecret). Some database setups (Unix sockets outside `$HOME`,
custom TLS stores) may need extra permissions, e.g.:

```bash
flatpak override --user com.queryahub.querya_desktop --filesystem=/var/run/postgresql:ro
```

Flathub submission can reuse [`packaging/linux/flatpak/com.queryahub.querya_desktop.yml`](../packaging/linux/flatpak/com.queryahub.querya_desktop.yml).
2 changes: 1 addition & 1 deletion docs/release-checklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ Verify the 0.4.4 motion tokens, smooth animations, and high refresh rate support
- [x] After merge to `main`, confirm any **Auto Version Bump** still yields a **0.4.11+…** product version (do not ship as 0.4.12).
- [x] **Tag** `0.4.11` is placed on the **commit that includes all fixes** you want in binaries (a tag does not auto-include later commits; see [CONTRIBUTING.md](../CONTRIBUTING.md)).
- [x] Run the **Release** workflow from GitHub Actions (see [tags-and-releases.md](tags-and-releases.md)).
- [ ] Verify **portable** zips (`*-linux.zip`, `*-windows.zip`, `*-macos.zip`), **installable** artifacts (`*.AppImage`, `*.deb`, `*-windows-setup.exe`), and `SHA256SUMS.txt` on the GitHub Release.
- [ ] Verify **portable** zips (`*-linux.zip`, `*-windows.zip`, `*-macos.zip`), **installable** artifacts (`*.AppImage`, `*.deb`, `*.rpm`, `*.flatpak`, `*-windows-setup.exe`), and `SHA256SUMS.txt` on the GitHub Release.

## Docs

Expand Down
6 changes: 5 additions & 1 deletion docs/tags-and-releases.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,17 @@
|----------|--------|
| `Querya-Desktop-X.Y.Z-linux.AppImage` | [`scripts/linux/build_appimage.sh`](../scripts/linux/build_appimage.sh) (`chmod +x` then run) |
| `Querya-Desktop-X.Y.Z-linux.deb` | Debian/Ubuntu — [`scripts/linux/build_deb.sh`](../scripts/linux/build_deb.sh) |
| `Querya-Desktop-X.Y.Z-linux.rpm` | Fedora/RHEL — [`scripts/linux/build_rpm.sh`](../scripts/linux/build_rpm.sh) |
| `Querya-Desktop-X.Y.Z-linux.flatpak` | Distro-agnostic — [`scripts/linux/build_flatpak.sh`](../scripts/linux/build_flatpak.sh) |
| `Querya-Desktop-X.Y.Z-windows-setup.exe` | Inno Setup (`packaging/windows/querya.iss`) |

```bash
sudo apt install ./Querya-Desktop-X.Y.Z-linux.deb
sudo dnf install ./Querya-Desktop-X.Y.Z-linux.rpm
flatpak install --user ./Querya-Desktop-X.Y.Z-linux.flatpak
```

RPM / Flatpak / AUR: [#386](https://github.com/QueryaHub/Querya-Desktop/issues/386) / epic [#379](https://github.com/QueryaHub/Querya-Desktop/issues/379).
**Arch (AUR):** community PKGBUILD — [`packaging/linux/aur/`](../packaging/linux/aur/) (installs the Release portable zip under `/opt`).

## Changelog в GitHub Release

Expand Down
39 changes: 39 additions & 0 deletions packaging/linux/aur/PKGBUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# Maintainer: QueryaHub <https://github.com/QueryaHub/Querya-Desktop>
# AUR package — installs the official Release portable Linux zip under /opt.
# Bump pkgver/pkgrel when a new GitHub Release is published.
pkgname=querya-desktop
pkgver=0.4.11
pkgrel=1
pkgdesc="Multi-database desktop client (PostgreSQL, MySQL, Redis, MongoDB, SQLite)"
arch=('x86_64')
url="https://github.com/QueryaHub/Querya-Desktop"
license=('MIT')
depends=('gtk3' 'libsecret' 'glib2')
optdepends=(
'libappindicator-gtk3: system tray / app indicator'
)
source=(
"Querya-Desktop-${pkgver}-linux.zip::https://github.com/QueryaHub/Querya-Desktop/releases/download/${pkgver}/Querya-Desktop-${pkgver}-linux.zip"
"querya_desktop.desktop"
)
sha256sums=('SKIP' 'SKIP')

prepare() {
bsdtar -xf "$srcdir/Querya-Desktop-${pkgver}-linux.zip" -C "$srcdir"
}

package() {
install -dm755 "$pkgdir/opt/querya-desktop"
cp -a "$srcdir"/{querya_desktop,lib,data} "$pkgdir/opt/querya-desktop/"

install -dm755 "$pkgdir/usr/bin"
ln -s /opt/querya-desktop/querya_desktop "$pkgdir/usr/bin/querya_desktop"

install -dm755 "$pkgdir/usr/share/applications"
install -Dm644 "$srcdir/querya_desktop.desktop" \
"$pkgdir/usr/share/applications/querya_desktop.desktop"

install -dm755 "$pkgdir/usr/share/icons/hicolor/512x512/apps"
install -Dm644 "$srcdir/querya_desktop.png" \
"$pkgdir/usr/share/icons/hicolor/512x512/apps/querya_desktop.png"
}
21 changes: 21 additions & 0 deletions packaging/linux/aur/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Arch Linux (AUR)

Community packaging for Arch-based distros. The PKGBUILD installs the official
**portable Linux zip** from GitHub Releases under `/opt/querya-desktop`.

## Before publishing to AUR

1. Copy `PKGBUILD`, `querya_desktop.desktop`, and `querya_desktop.png` into a clean build directory.
2. Bump `pkgver` / `pkgrel` to match the GitHub Release tag and AUR revision.
3. Run `makepkg -si` locally and smoke-launch `querya_desktop`.
4. Generate `.SRCINFO`: `makepkg --printsrcinfo > .SRCINFO`
5. Push to your AUR repo (e.g. `querya-desktop`).

`querya_desktop.desktop` and the 512×512 icon are the same assets used by
`.deb` / `.rpm` packaging (`packaging/linux/querya_desktop.desktop` and
`macos/Runner/Assets.xcassets/.../app_icon_512.png`).

## Updates

Prefer **`pacman -Syu`** / AUR helper updates over the in-app zip/AppImage
updater when running this package build.
10 changes: 10 additions & 0 deletions packaging/linux/aur/querya_desktop.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[Desktop Entry]
Type=Application
Name=Querya Desktop
Comment=Multi-database desktop client
Exec=querya_desktop
Icon=querya_desktop
Categories=Development;Database;
Terminal=false
StartupWMClass=querya_desktop
X-Querya-AppId=com.queryahub.querya_desktop
Binary file added packaging/linux/aur/querya_desktop.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 9 additions & 0 deletions packaging/linux/flatpak/com.queryahub.querya_desktop.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[Desktop Entry]
Type=Application
Name=Querya Desktop
Comment=Multi-database desktop client
Exec=querya_desktop
Icon=com.queryahub.querya_desktop
Categories=Development;Database;
Terminal=false
StartupWMClass=querya_desktop
29 changes: 29 additions & 0 deletions packaging/linux/flatpak/com.queryahub.querya_desktop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Flatpak manifest for Querya Desktop (Flutter GTK bundle).
# Built by scripts/linux/build_flatpak.sh — bundle/ is copied next to this file at build time.
app-id: com.queryahub.querya_desktop
runtime: org.gnome.Platform
runtime-version: '48'
sdk: org.gnome.Sdk
command: querya_desktop

finish-args:
- --share=network
- --share=ipc
- --socket=fallback-x11
- --socket=wayland
- --device=dri
- --filesystem=home
- --talk-name=org.freedesktop.secrets

modules:
- name: querya-desktop
buildsystem: simple
build-commands:
- install -Dm755 querya_desktop /app/bin/querya_desktop
- cp -a lib /app/
- cp -a data /app/
- install -Dm644 com.queryahub.querya_desktop.desktop /app/share/applications/com.queryahub.querya_desktop.desktop
- install -Dm644 com.queryahub.querya_desktop.png /app/share/icons/hicolor/512x512/apps/com.queryahub.querya_desktop.png
sources:
- type: dir
path: bundle
44 changes: 44 additions & 0 deletions packaging/linux/querya-desktop.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# RPM spec for Querya Desktop (built via scripts/linux/build_rpm.sh).
# Macros querya_bundle, querya_icon, querya_desktop_file, and version are passed on the command line.

Name: querya-desktop
Version: %{version}
Release: 1%{?dist}
Summary: Querya Desktop database client
License: MIT
URL: https://github.com/QueryaHub/Querya-Desktop
BuildArch: x86_64
Requires: gtk3 >= 3.22
Requires: libsecret >= 0.18
Requires: glib2 >= 2.56
Recommends: libappindicator-gtk3

%description
Multi-database desktop client for PostgreSQL, MySQL, Redis, MongoDB,
SQLite, and sandboxed drivers.

%prep
# Pre-built Flutter bundle; no source compile in this packaging path.

%build
# no-op

%install
rm -rf %{buildroot}
mkdir -p %{buildroot}/opt/querya-desktop
cp -a %{querya_bundle}/. %{buildroot}/opt/querya-desktop/
chmod +x %{buildroot}/opt/querya-desktop/querya_desktop
mkdir -p %{buildroot}/usr/bin
ln -s /opt/querya-desktop/querya_desktop %{buildroot}/usr/bin/querya_desktop
mkdir -p %{buildroot}/usr/share/applications
mkdir -p %{buildroot}/usr/share/icons/hicolor/512x512/apps
install -m 644 %{querya_desktop_file} %{buildroot}/usr/share/applications/querya_desktop.desktop
install -m 644 %{querya_icon} %{buildroot}/usr/share/icons/hicolor/512x512/apps/querya_desktop.png

%files
/opt/querya-desktop
/usr/bin/querya_desktop
/usr/share/applications/querya_desktop.desktop
/usr/share/icons/hicolor/512x512/apps/querya_desktop.png

%changelog
10 changes: 10 additions & 0 deletions packaging/linux/querya_desktop.desktop
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[Desktop Entry]
Type=Application
Name=Querya Desktop
Comment=Multi-database desktop client
Exec=querya_desktop
Icon=querya_desktop
Categories=Development;Database;
Terminal=false
StartupWMClass=querya_desktop
X-Querya-AppId=com.queryahub.querya_desktop
16 changes: 2 additions & 14 deletions scripts/linux/build_deb.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@ set -euo pipefail
ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/../.." && pwd)"
BUNDLE="${1:-$ROOT/build/linux/x64/release/bundle}"
BINARY_NAME="querya_desktop"
# Keep in sync with linux/CMakeLists.txt APPLICATION_ID (and #385 when merged).
APP_ID="${QUERYA_LINUX_APP_ID:-com.queryahub.querya_desktop}"
ICON_SRC="$ROOT/macos/Runner/Assets.xcassets/AppIcon.appiconset/app_icon_512.png"

if [[ ! -d "$BUNDLE" ]]; then
Expand Down Expand Up @@ -51,18 +49,8 @@ if [[ -f "$ICON_SRC" ]]; then
cp "$ICON_SRC" "$PKG/usr/share/icons/hicolor/512x512/apps/${BINARY_NAME}.png"
fi

cat > "$PKG/usr/share/applications/${BINARY_NAME}.desktop" <<EOF
[Desktop Entry]
Type=Application
Name=Querya Desktop
Comment=Multi-database desktop client
Exec=${BINARY_NAME}
Icon=${BINARY_NAME}
Categories=Development;Database;
Terminal=false
StartupWMClass=querya_desktop
X-Querya-AppId=${APP_ID}
EOF
cp "$ROOT/packaging/linux/querya_desktop.desktop" \
"$PKG/usr/share/applications/${BINARY_NAME}.desktop"

# Rough installed size in KiB for the control file.
INSTALLED_SIZE="$(du -sk "$PKG" | awk '{print $1}')"
Expand Down
Loading
Loading