forked from jsnbuchanan/crowd-funder-for-time-pwa
feat: Add comprehensive Electron build script and automation
- Create build-electron.sh script following build-android.sh patterns - Add support for multiple build modes: dev, package, appimage, deb - Implement comprehensive error handling with specific exit codes - Add proper logging and step-by-step build process tracking - Include built-in help system and verbose logging options Build Script Features: - Development builds that compile and launch Electron app - Package builds for creating distributable applications - Support for AppImage and Debian package generation - Automatic cleanup of previous builds and artifacts - TypeScript compilation with proper error handling - Capacitor sync and asset generation integration NPM Script Integration: - Add build:electron for development builds - Add build:electron:package for distributable packages - Add build:electron:appimage for AppImage packages - Add build:electron:deb for Debian packages - Add clean:electron for build artifact cleanup Common Utilities Enhancement: - Extend setup_build_env() to support 'electron' build type - Configure proper environment variables for Electron builds - Maintain consistency with existing build infrastructure This provides a complete, automated build solution for Electron that matches the quality and functionality of the Android build system, enabling reliable cross-platform desktop application builds.
This commit is contained in:
@@ -182,6 +182,12 @@ setup_build_env() {
|
||||
export VITE_DISABLE_PWA=true
|
||||
export DEBUG_MIGRATIONS=0
|
||||
;;
|
||||
"electron")
|
||||
export VITE_PLATFORM=capacitor
|
||||
export VITE_PWA_ENABLED=false
|
||||
export VITE_DISABLE_PWA=true
|
||||
export DEBUG_MIGRATIONS=0
|
||||
;;
|
||||
"web")
|
||||
export VITE_PLATFORM=web
|
||||
export VITE_PWA_ENABLED=true
|
||||
|
||||
Reference in New Issue
Block a user