Skip to content

Commit 8f4c64d

Browse files
committed
Refactor Tauri build process to streamline bundle targets and enhance artifact handling
- Updated build.sh to exclude AppImage from local builds, simplifying the bundle target determination for Linux. - Modified GitHub Actions workflow to specify bundle types for Tauri builds and added logic to include standalone binaries for Linux, Windows, and macOS. - Removed AppImage from tauri.conf.json to reflect the updated build strategy. These changes improve the clarity and efficiency of the build process, ensuring only relevant bundles are created and enhancing the management of standalone binaries.
1 parent 6570db7 commit 8f4c64d

File tree

3 files changed

+25
-11
lines changed

3 files changed

+25
-11
lines changed

.github/workflows/release.yml

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ jobs:
123123

124124
- name: Build Tauri app
125125
working-directory: frontend
126-
run: bunx tauri build
126+
run: bunx tauri build --bundles deb,rpm,appimage
127127
# Optional: Set these secrets in GitHub Settings → Secrets for code signing
128128
# If not set, Tauri will build without signing (linter warnings are expected)
129129
env:
@@ -364,6 +364,13 @@ jobs:
364364
rm -rf portable-linux
365365
fi
366366
367+
# Linux: Add standalone binary
368+
if [ -f "artifacts/linux/budget-planer" ]; then
369+
cp artifacts/linux/budget-planer release_artifacts/budget-planer-linux
370+
chmod +x release_artifacts/budget-planer-linux
371+
echo "✓ Added Linux standalone binary"
372+
fi
373+
367374
# Linux: Add bundle types
368375
find artifacts/linux -name "*.deb" -type f 2>/dev/null | while read -r file; do
369376
cp "$file" release_artifacts/
@@ -408,6 +415,12 @@ jobs:
408415
fi
409416
done
410417
418+
# Windows: Add standalone binary
419+
if [ -f "artifacts/windows/budget-planer.exe" ]; then
420+
cp artifacts/windows/budget-planer.exe release_artifacts/budget-planer-windows.exe
421+
echo "✓ Added Windows standalone binary"
422+
fi
423+
411424
# macOS: Create portable ZIP with binary + backend-server
412425
if [ -f "artifacts/macos/budget-planer" ]; then
413426
mkdir -p portable-macos
@@ -426,6 +439,13 @@ jobs:
426439
rm -rf portable-macos
427440
fi
428441
442+
# macOS: Add standalone binary
443+
if [ -f "artifacts/macos/budget-planer" ]; then
444+
cp artifacts/macos/budget-planer release_artifacts/budget-planer-macos
445+
chmod +x release_artifacts/budget-planer-macos
446+
echo "✓ Added macOS standalone binary"
447+
fi
448+
429449
# macOS: Add DMG and PKG
430450
find artifacts/macos -name "*.dmg" -type f 2>/dev/null | while read -r file; do
431451
cp "$file" release_artifacts/

build.sh

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -251,17 +251,12 @@ if [ "$BUILD_FRONTEND" = true ]; then
251251
print_info "Building Tauri application ($BUILD_TYPE mode)..."
252252
cd "$FRONTEND_DIR"
253253

254-
# Determine which bundles to build based on platform and available tools
254+
# Determine which bundles to build based on platform
255+
# Note: AppImage is excluded from local builds (requires linuxdeploy)
256+
# CI builds AppImage separately with linuxdeploy installed
255257
BUNDLE_TARGETS=""
256258
if [ "$PLATFORM" == "linux" ]; then
257-
# Check if linuxdeploy is available for AppImage builds
258-
if command_exists linuxdeploy || [ -f "/usr/local/bin/linuxdeploy" ]; then
259-
print_success "linuxdeploy found - AppImage will be built"
260-
BUNDLE_TARGETS="deb,rpm,appimage"
261-
else
262-
print_warning "linuxdeploy not found - skipping AppImage (install with: sudo wget -q https://github.com/linuxdeploy/linuxdeploy/releases/download/continuous/linuxdeploy-x86_64.AppImage -O /usr/local/bin/linuxdeploy && sudo chmod +x /usr/local/bin/linuxdeploy)"
263-
BUNDLE_TARGETS="deb,rpm"
264-
fi
259+
BUNDLE_TARGETS="deb,rpm"
265260
elif [ "$PLATFORM" == "macos" ]; then
266261
BUNDLE_TARGETS="dmg,app"
267262
elif [ "$PLATFORM" == "windows" ]; then

frontend/src-tauri/tauri.conf.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@
3131
"targets": [
3232
"deb",
3333
"rpm",
34-
"appimage",
3534
"dmg",
3635
"app",
3736
"msi",

0 commit comments

Comments
 (0)