CLI Reference
The naide command-line tool compiles, runs, tests, and manages NAIDE projects.
Basic Usage
$ naide <file> # Compile and run
$ naide <file> -o out.mjs # Compile to file
$ naide <file> -w # Watch mode (auto-recompile)
Compilation Targets
$ naide app.naide # Node.js (default)
$ naide app.naide --target python # Python / Flask
$ naide app.naide --target bun # Bun runtime
$ naide app.naide -t py # Short alias
| Target | Output | Server |
|---|---|---|
node (default) | JavaScript (.mjs) | Express |
python / py | Python (.py) | Flask |
bun | JavaScript (.js) | Bun.serve() |
Type Checking
$ naide --check app.naide # Type-check only, no run
$ naide check app.naide # Same as above
Debugging
$ naide app.naide --debug # Launch with Chrome DevTools
$ naide app.naide -d # Short alias
Opens node --inspect-brk for step-through debugging in Chrome DevTools.
Testing
$ naide test tests.naide # Run test file
Package Ecosystem
$ naide pkg init # Initialize package.json
$ naide pkg install <name> # Install a package
$ naide pkg publish # Publish to npm
$ naide pkg list # List installed packages
Deployment
$ naide deploy # Generate Dockerfile
Generates a production Dockerfile with multi-stage build.
NX Conversion
$ naide convert app.naide # Convert .naide to .nx
REPL
$ naide # Interactive REPL
NAIDE v1.10.0 REPL
> str name = "World"
> log "Hello, {name}!"
Hello, World!
All Flags
| Flag | Description |
|---|---|
-o <file> | Output compiled code to file |
-w, --watch | Watch mode |
-t, --target | Compilation target (node/python/bun) |
-d, --debug | Debug mode with Chrome DevTools |
--check | Type-check only |
--ast | Print AST |
--tokens | Print tokens |
-h, --help | Show help |
-v, --version | Show version |