Add Arch/Manjaro (pacman) bundling target#53
Open
thfaix wants to merge 3 commits into
Open
Conversation
Linux builds now produce a .pacman package alongside AppImage and deb, installable via `sudo pacman -U`. CI installs libarchive-tools on the Ubuntu runners (provides bsdtar, required by fpm's pacman backend) and uploads dist/*.pacman with the other Linux artifacts. README adds a Building on Arch / Manjaro note: building deb/pacman locally on Arch requires libxcrypt-compat because the bundled fpm links against libcrypt.so.1.
- pacman.depends: drop bogus deb-style defaults (http-parser etc.) and declare real Arch packages (gtk3, nss, libnotify, libxtst, libxss, xdg-utils, libsecret) so 'pacman -U' can resolve. - pacman.packageName: rename to 'switchboard-doctly' to avoid conflict with extra/switchboard (Pantheon Control Center). - linux.icon: point at build/icons/ so electron-builder installs PNGs at standard hicolor sizes (16-512). The single 472x472 source was being installed at hicolor/472x472/apps/ which no desktop environment looks in, so the launcher fell back to a generic icon. generate-icons.js now also produces these sizes.
- pacman.artifactName: emit 'switchboard-doctly-<version>.pacman' so the released file matches the installed pkgname. Avoids confusion when users search release assets for the package they have installed. - README: explain WHY the pacman package is renamed (collides with extra/switchboard, the Pantheon Control Center on elementary OS) and document the uninstall command 'sudo pacman -R switchboard-doctly'. - scripts/generate-icons.js: hoist duplicate 'png2icons' and '@napi-rs/canvas' requires to the top. Node caches require(), so this was harmless duplication — just clearer this way.
|
+1 — clean separation between the Arch quirks and the existing deb/AppImage path. The hicolor icon set + CI artifact upload are nice housekeeping bonuses I'd want even on non-Arch builds. Tested-on note for AppImage/deb regressions in the PR body is reassuring. Not an Arch user myself but I'd merge this. |
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.
Summary
pacmanto the Linux electron-builder targets so the app can be packaged for Arch/Manjaro alongside AppImage and deb.gtk3,nss,libnotify,libxtst,libxss,xdg-utils,libsecret) sopacman -Ucan actually resolve — electron-builder's default deps shipped Debian-style names (http-parser, etc.) that don't exist in Arch repos.switchboard-doctly(with matchingartifactName) to avoid a collision withextra/switchboard(elementary OS's Pantheon Control Center). The displayed app name stays "Switchboard" everywhere — only the package identity changes./usr/share/icons/hicolor/472x472/apps/, a non-standard size no desktop environment looks in.libarchive-toolson Ubuntu runners (providesbsdtarfor fpm's pacman backend) and uploadsdist/*.pacmanwith the other Linux artifacts.libxcrypt-compatrequirement for building deb/pacman locally on Arch, and the package-name rationale.Test plan
npm run build:linuxon Manjaro producesdist/switchboard-doctly-0.0.30.pacmanalongside AppImage + debbsdtar -xOf … .PKGINFOshowspkgname=switchboard-doctly, correct Arch deps, nohttp-parsersudo pacman -U dist/switchboard-doctly-0.0.30.pacmaninstalls cleanly (no unresolved deps, no name conflict)/usr/share/icons/hicolor/{16,32,48,64,128,256,512}/apps/switchboard.png); launcher displays the Switchboard icon.pacmanartifact on the Linux jobNotes for reviewers
.icnsand Windows.icobuild paths are untouched.linux.icon: build/iconsdirectory is committed;scripts/generate-icons.jsregenerates it frombuild/icon.pngif anyone re-runsnpm run generate-icons.libxcrypt-compat(the bundled fpm links againstlibcrypt.so.1which Arch dropped). AppImage builds without it. Documented in the README's "Building on Arch / Manjaro" section.