v1.0.2Latest / April 2026
Installation
Install the Gun CLI with npm or Bun, then verify it from your terminal.
Requirements
Check the local tools:
node --version
npm --version
go version
Recommended versions:
- Node.js 18 or newer, or Bun 1.x.
- Go 1.21 or newer.
- A project entrypoint such as
src/index.ts,src/server.ts, orserver.js.
npm
Install globally:
npm i -g gun-transpiler
Install per project:
npm i -D gun-transpiler
Use npx when the CLI is local:
npx gun check src/index.ts
Bun
Install per project:
bun add -d gun-transpiler
Use bunx when needed:
bunx gun check src/index.ts
Verify
gun --version
gun help
If gun is not found, use the package runner for your install style:
npx gun --version
bunx gun --version
Add scripts
Add repeatable commands to package.json:
{
"scripts": {
"gun:check": "gun check src/index.ts",
"gun:build": "gun transpile src/index.ts -o build/gun",
"gun:watch": "gun watch src/index.ts -o build/gun"
}
}
Run the scripts in CI and during local development so every environment uses the same entrypoint and output path.