Turn any website into a lightweight desktop app with one command, on macOS, Windows and Linux.
Rust chatgptclaudeclidesktopdesktop-appelectron-alternativegeminilinuxmacosnativefierno-electronrusttauriweb-to-desktopwebsite-to-appwebviewwindowsyoutube
feat: add cli-only rpm build support (#1107)
Tw9330c4a467253f
diff --git a/bin/builders/LinuxBuilder.ts b/bin/builders/LinuxBuilder.tsindex 6a8c0559..920f2f2d 100644--- a/bin/builders/LinuxBuilder.ts+++ b/bin/builders/LinuxBuilder.ts@@ -6,6 +6,7 @@ import tauriConfig from '@/helpers/tauriConfig';export default class LinuxBuilder extends BaseBuilder {private buildFormat: string;private buildArch: string;+ private currentBuildType: string = '';constructor(options: PakeAppOptions) {super(options);@@ -43,7 +44,7 @@ export default class LinuxBuilder extends BaseBuilder {}}- if (targets === 'rpm') {+ if (this.currentBuildType === 'rpm') {return `${name}-${version}-1.${arch}`;}@@ -58,11 +59,18 @@ export default class LinuxBuilder extends BaseBuilder {for (const target of targetTypes) {if (requestedTargets.includes(target)) {+ this.currentBuildType = target;await this.buildAndCopy(url, target);}}}+ // Override buildAndCopy to ensure currentBuildType is synced if called directly, though the loop above handles it most of the time.+ async buildAndCopy(url: string, target: string) {+ this.currentBuildType = target;+ await super.buildAndCopy(url, target);+ }+protected getBuildCommand(packageManager: string = 'pnpm'): string {const configPath = path.join('src-tauri', '.pake', 'tauri.conf.json');@@ -82,12 +90,16 @@ export default class LinuxBuilder extends BaseBuilder {fullCommand += ` --features ${features.join(',')}`;}+ if (this.currentBuildType) {+ fullCommand += ` --bundles ${this.currentBuildType}`;+ }+// Enable verbose output for AppImage builds when debugging or PAKE_VERBOSE is set.// AppImage builds often fail with minimal error messages from linuxdeploy,// so verbose mode helps diagnose issues like strip failures and missing dependencies.if (- this.options.targets === 'appimage' &&- (this.options.debug || process.env.PAKE_VERBOSE)+ this.currentBuildType === 'appimage' &&+ (this.options.targets.includes('appimage') || this.options.debug || process.env.PAKE_VERBOSE)) {fullCommand += ' --verbose';}diff --git a/bin/defaults.ts b/bin/defaults.tsindex e05b124c..b5a13e6c 100644--- a/bin/defaults.ts+++ b/bin/defaults.ts@@ -19,7 +19,7 @@ export const DEFAULT_PAKE_OPTIONS: PakeCliOptions = {targets: (() => {switch (process.platform) {case 'linux':- return 'deb';+ return 'deb,appimage';case 'darwin':return 'dmg';case 'win32':