An installable Electron app for running JavaScript and TypeScript snippets locally.
npm installnpm run devnpm run dist
npm run dist builds the renderer with Vite and creates installable artifacts in release/.
The GitHub Releases tab can be the only download surface. Once a tagged workflow finishes, users can download the compiled macOS, Windows, and Linux artifacts directly from the Releases page.
You can still use this release flow without Apple Developer enrollment or Windows signing certificates. In that case, GitHub Releases will still get downloadable build artifacts, but macOS and Windows users will see stronger OS trust warnings because those builds are unsigned or unnotarized.
To have downloadable executable files appear in the GitHub Releases tab, you only need:
- Push this repository to GitHub.
- Make sure GitHub Actions is enabled for the repo.
- Push a version tag, for example:
git tag v0.1.0git push origin v0.1.0
- Wait for the workflow in release.yml to finish.
- Open the GitHub Releases page and download the generated artifacts.
That is enough to get:
- macOS
.dmgand.zip - Windows
.exe - Linux
.AppImageand.deb SHA256SUMS-<platform>.txtchecksum files
No Apple Developer account is required for that basic release flow.
If you are not enrolled in the Apple Developer Program yet:
- macOS builds will not be Developer ID signed.
- macOS builds will not be notarized.
- Users will see Gatekeeper warnings when opening the app.
- Some users may need to right-click the app and choose
Open, or allow it manually in System Settings. - The app will feel less trustworthy to end users than a notarized build.
If you also do not have a Windows signing certificate:
- Windows builds will still be downloadable.
- Users will see SmartScreen or publisher warnings before opening the installer.
Linux is the least affected:
- Linux artifacts can still be released normally.
- Linux distribution usually does not depend on the same signing and notarization flow as macOS and Windows.
- User code runs in a dedicated Web Worker, not in the Electron main process.
- The Electron window uses
contextIsolation,sandbox, andnodeIntegration: false. - The app denies all permission prompts.
- The app blocks in-app navigation, popups, and
webviewattachment. - Outbound network requests are blocked for packaged builds and disabled inside the code runner.
- The sandbox disables
fetch,XMLHttpRequest,WebSocket,EventSource, nested workers,importScripts, and persistent browser storage APIs. - The runner enforces a 5 second execution timeout, source size and line limits, transpiled output limits, timer caps, and output limits to reduce abuse and accidental lockups.
- If the renderer hangs or crashes, the Electron window reloads or recreates itself instead of leaving the app dead.
- Build each platform on its native OS, or use CI runners for macOS, Windows, and Linux.
- Review the generated icon assets in
build/before publishing. - Optional but recommended: sign the app:
- macOS: Apple Developer ID Application certificate, then notarize the
.app/.dmg - Windows: Authenticode code signing certificate
- macOS: Apple Developer ID Application certificate, then notarize the
- Test the packaged artifacts, not just
npm run dev. - Publish the GitHub Release artifacts.
- Push a tag like
v0.1.0to trigger release.yml. - The workflow builds on macOS, Windows, and Linux runners.
electron-builderpublishes release assets directly to GitHub Releases throughGH_TOKEN.- The macOS build signs with
MACOS_CSC_LINKandMACOS_CSC_KEY_PASSWORD, then notarizes withAPPLE_ID,APPLE_APP_SPECIFIC_PASSWORD, andAPPLE_TEAM_ID. - The Windows build signs with
WINDOWS_CSC_LINKandWINDOWS_CSC_KEY_PASSWORD. - Linux artifacts are built automatically, but standard Electron Linux targets are usually distributed unsigned.
- Each platform job also uploads a
SHA256SUMS-<platform>.txtfile to the same GitHub Release. - If signing secrets are missing, the workflow still publishes unsigned artifacts instead of failing.
Once you are enrolled in the Apple Developer Program, add these GitHub repository secrets:
MACOS_CSC_LINKMACOS_CSC_KEY_PASSWORDAPPLE_IDAPPLE_APP_SPECIFIC_PASSWORDAPPLE_TEAM_ID
If you later buy a Windows code-signing certificate, add:
WINDOWS_CSC_LINKWINDOWS_CSC_KEY_PASSWORD
After those secrets are present, the same tagged release flow will start producing signed and, on macOS, notarized builds automatically.
MACOS_CSC_LINK: Base64 or file URL for the Developer ID Application certificate.MACOS_CSC_KEY_PASSWORD: Password for the macOS signing certificate.WINDOWS_CSC_LINK: Base64 or file URL for the Windows Authenticode certificate.WINDOWS_CSC_KEY_PASSWORD: Password for the Windows signing certificate.APPLE_ID: Apple ID used for notarization.APPLE_APP_SPECIFIC_PASSWORD: App-specific password for that Apple ID.APPLE_TEAM_ID: Apple Developer team identifier.
The notarization hook lives in scripts/notarize.js and the hardened runtime entitlements are in entitlements.mac.plist.
- The packaged app name is
Marathon. - The temporary release icon is generated from icon.svg into
build/icon.pngduringnpm run build.
- This is a local practice sandbox, not a secure environment for running untrusted third-party code.
- Very large TypeScript inputs can still stress the renderer before execution begins because transpilation happens in the renderer process.
- Unsigned macOS builds will trigger Gatekeeper warnings, and unsigned Windows builds will trigger SmartScreen warnings.