Skip to content
Main site
Developer SDK & LSPM4

Hadid CLI & Shell-Free Portable Builds

Complete CLI command reference, fork/execvp shell-free native compilation, and libhadid_rt.a linking.

5 min readUpdated: v0.8.0-rc Reference

CLI Command Reference

CommandPurpose
`hadid new <name> [--lang tr\en]`Scaffolds hadid.toml, src/main.had, tests/basic_test.had
hadid check [file]Runs lexer, parser, module resolver, and static type checker
hadid run [file] [args...]Executes directly in the Hadid interpreter
hadid build [file] [-o out]Emits C17 and links against libhadid_rt.a into a native binary
hadid test [path]Discovers *_test.had / test_*.had and verifies interpreter = native parity
`hadid fmt [-p\-w] <files>`Formats Hadid source files
hadid deps / hadid lockResolves hadid.toml dependencies and writes hadid.lock
hadid lspStarts the JSON-RPC 2.0 language server over stdio

Zero-Shell, Concurrency-Safe Compilation

hadid build creates a unique mkdtemp workspace per invocation, invokes CC directly via fork/execvp/waitpid (no system() shell interpolation), supports paths with spaces, and links prebuilt libhadid_rt.a for fast native builds.