Skip to content

Packaging & Releases

Kangentic uses electron-builder to create platform-specific installers. Configuration lives in electron-builder.yml at the project root.

PlatformFormatInstaller Type
Windows.exeNSIS (Nullsoft Scriptable Install System)
macOS.dmgDisk image with drag-to-install
Linux.deb, .rpmNative package manager formats

Several native modules require special handling during packaging:

ModuleStrategy
better-sqlite3Rebuilt for the target Electron version via electron-builder rebuild
node-ptyUses prebuilt binaries; falls back to rebuild if prebuilds unavailable
Bridge scriptSelectively unpacked from ASAR to allow process spawning

The app is packaged as an ASAR archive for faster loading and to prevent casual modification. Selective unpacking is configured for:

  • Native .node modules that require filesystem access
  • The bridge script used for process spawning

Production builds set Electron security fuses to harden the application:

FuseSettingPurpose
RunAsNodeDisabledPrevents ELECTRON_RUN_AS_NODE environment variable
NodeOptionsDisabledPrevents NODE_OPTIONS injection
InspectionDisabledPrevents --inspect debugging in production
Cookie EncryptionEnabledEncrypts cookies at rest
ASAR IntegrityEnabledValidates ASAR archive integrity on load

Windows builds are signed using Azure Trusted Signing. The CI pipeline authenticates with Azure credentials and signs the NSIS installer during the build step.

macOS builds use:

  • Hardened runtime — required for notarization
  • Apple notarization — the DMG is submitted to Apple’s notary service and stapled before release

Releases follow a structured process:

  1. Trigger: Run /release patch|minor|major in the repo — this bumps the version and pushes a git tag
  2. CI Build: The tag push triggers GitHub Actions, which builds on all three platforms (ubuntu, windows, macos)
  3. Draft Release: CI creates a draft GitHub Release with all platform artifacts attached
  4. Manual Review: A maintainer reviews the draft release and the build artifacts
  5. Publish: The maintainer publishes the release — this makes it visible to the auto-updater
  6. npm Publish: The launcher package is published to npm so npx kangentic downloads the new version

The release workflow uses GitHub environment protection rules:

  • Required reviewers must approve the deployment
  • The production environment is protected with branch restrictions
RunnerPlatformArtifact
ubuntu-latestLinux.deb, .rpm
windows-latestWindowsNSIS .exe
macos-latestmacOS.dmg
Terminal window
# Build the app without creating an installer
npm run package
# Create distributable installers locally
npm run make
# Test the full publish pipeline (dry run)
npm run publish -- --dry-run