Docs/Reference
zli.json
The project file that sets up worktrees and shares prompts with your team.
zli.json is a project file at the root of your repository. Commit it, and everyone on your team gets the same worktree setup and shared prompts.
Example
{
"version": 1,
"worktree": {
"copy": [".env", "apps/web/.env.local"],
"setup": ["pnpm install --frozen-lockfile"]
},
"prompts": [
{ "name": "Review", "prompt": "Review the changes on this branch for bugs." }
]
}
Fields
| Field | Type | Description |
|---|---|---|
version | 1 | Required. Must be 1. |
worktree.copy | list of paths or globs | Files copied from the main checkout into each new worktree, such as .env. Up to 100. |
worktree.setup | list of commands | Shell commands run in order inside each new worktree after the copy. Up to 20. |
prompts | list of { name, prompt } | Prompts shared with everyone who opens the project. Up to 100. |
$schema | string | Optional, for editor support. |
Rules for copy paths
Paths are relative to the repository root and use forward slashes. A path cannot:
- start with
/or a drive letter, - contain
..or empty segments, - start with
!(no negations), - point into
.git.
Rules for setup commands
Put each command on its own line in the list; a command cannot contain a line break. Setup commands always ask before they run, and each runs in its own terminal.
Errors
If the file is not valid, ZLI names the field that failed, for example worktree.copy.0. The file can be up to 256 KB.