Sections
Documentation › Administer
noyau.json: versioned project configuration
A file at the root of the project, committed with the code. t3.json is read as a fallback, with T3's flat keys (defaultThreadEnvMode, worktreeSubmodules, worktreeSparsePatternsPath, ignoreRepositories, worktreeLayout, iconPath): a T3 project works without conversion.
Settings: project card → "Worktrees, scripts and repositories (noyau.json)". The "Create noyau.json" button offers a skeleton based on package.json.
Example
{
"defaultWorktree": true,
"icon": "public/favicon.svg",
"worktrees": {
"branchPrefix": "agent/",
"branchNaming": "semantic",
"folderName": "{repo}-{slug}",
"submodules": "recursive",
"sparsePatternsPath": ".noyau/sparse.txt",
"copyFiles": [".env.local"],
"linkFiles": ["node_modules"],
"layout": { "create": "./scripts/wt-create.sh", "remove": "./scripts/wt-remove.sh" }
},
"repositories": { "include": ["libs/shared"], "ignore": ["old"] },
"autoPull": true,
"scripts": [
{ "name": "Dev", "command": "npm run dev -- --port {port}", "icon": "play", "previewUrl": "http://localhost:{port}", "autoOpenPreview": true, "stopOnSettle": true, "shortcut": "mod+shift+d" },
{ "name": "Install", "command": "npm ci", "runOnWorktreeCreate": true, "async": false },
{ "name": "Tests", "command": "npm test", "icon": "test", "runOnSettle": true }
]
}
Fields
| Key | Default | Purpose |
|---|---|---|
defaultWorktree |
false |
Each new agent in its own worktree (interface, CLI, teams). |
worktrees.branchPrefix |
agent/ |
Branch prefix. |
worktrees.branchNaming |
prefix |
semantic: feat/, fix/, refactor/, test/, docs/, perf/, chore/ depending on the instruction. |
worktrees.folderName |
{repo}-{slug} |
Must contain {slug}; {repo}, {project} allowed. |
worktrees.submodules |
recursive |
recursive, top-level, none. |
worktrees.sparsePatternsPath |
— | Pattern file (non-cone syntax) in the repository. |
worktrees.copyFiles |
[] |
Copied from the main folder (copy-on-write if the file system supports it). |
worktrees.linkFiles |
[] |
Symbolic links to the main folder. |
worktrees.layout |
— | create / remove scripts that build the worktree themselves. Approval required. |
repositories.include / ignore |
[] |
Multi-repository: add deeper repositories, exclude some. |
autoPull |
false |
Fast-forward of the main folder every 5 min. |
scripts |
[] |
See below (50 max). |
worktrees.location is rejected in the file: the location is specific to each machine and is set in the project (empty = .noyau-worktrees next to the repository).
Inheritance
Project setting → server defaults (main profile, PUT /api/project-defaults) → noyau.json → built-in default. The interface shows the source of each value. A local script with the same id replaces the one from the file.
Scripts
| Key | Purpose |
|---|---|
name, command, id, icon, cwd, env |
icon: play, test, lint, configure, build, debug. cwd relative to the project. |
runOnWorktreeCreate |
Run when an agent's worktree is created. async: false: awaited, in order, stopping at the first failure (reported to the agent). |
runOnSettle |
Run at the end of a turn, in a worktree only. |
stopOnSettle |
Stopped at the end of a turn (dev server). |
previewUrl, autoOpenPreview |
Preview link; when started by hand (card, palette, shortcut), the preview opens as soon as the port responds. |
shortcut |
Global shortcut (mod+shift+d); also in the command palette (Scripts). |
Variables in command and previewUrl: {port} (5400–5499, also $PORT), {branch}, {worktree}, {project}.
Approvals
Any command from the file that runs without a click (runOnWorktreeCreate, runOnSettle, worktrees.layout.*) must be approved once in the project. The approval covers the fingerprint of the exact command: if a commit changes it, it goes back to pending. An agent (master token) cannot approve: 403. Local scripts, written in Noyau, do not need approval.
Layout script
Receives NOYAU_PROJECT_ROOT, NOYAU_WORKTREE_ROOT, NOYAU_WORKTREE_PROJECT_PATH, NOYAU_WORKTREE_BRANCH, NOYAU_WORKTREE_BASE, NOYAU_WORKTREE_REPOSITORIES (and the same as T3_*). 10 min timeout, only one at a time per project, rollback on failure; Noyau checks that a linked git worktree was actually created.
Multi-repository
Repositories found at the first level (and one level below folders that are not repositories), plus include and the project's external folders. The worktree reproduces the tree: one worktree per chosen repository, links to the other files. Beyond 8 repositories, an agent receives only the one it works in, unless chosen explicitly (repositories at creation).
Automatic pull
Fast-forward only, never a merge. Skipped with a reason: detached HEAD, a branch other than the default branch, no upstream, local changes (untracked files included), local commits, failed fetch. "Pull now" button and POST /api/projects/:id/pull.
CLI
noyau-agent create --name x --prompt "…" follows defaultWorktree; --worktree forces it, --no-worktree / --local disables it.
API
| Route | Purpose |
|---|---|
GET/PUT /api/projects/:id/setup |
Full view, project settings. |
POST /api/projects/:id/setup/approve, /setup/init |
Approval, skeleton creation (humans only). |
GET /api/projects/:id/scripts, POST …/scripts/:scriptId/run and /stop |
Runs (optional sessionId). |
GET /api/project-scripts |
Scripts of visible projects (palette, shortcuts). |
GET/PUT /api/project-defaults |
Server defaults. |