First Steps
Create a project
dcr new my-app
cd my-app
Structure:
my-app/
├── dcr.toml
└── src/
└── main.c
dcr.toml:
[package]
name = "my-app"
version = "0.1.0"
type = "none"
[build]
language = "c"
standard = "c11"
compiler = "clang"
kind = "bin"
Build
dcr build
Output — target/<triple>/debug/my-app (Linux) or target/debug/my-app.exe (Windows).
Build profiles:
dcr build --release # release build
dcr build --debug # debug (default)
Run
dcr run
Builds (if needed) and runs the binary.
First test
dcr test --init # create test template
dcr test # run tests
Formatting
dcr fmt # clang-format with .clang-format