Configuration
Configuration
The current alpha selects one TOML file and exposes a small, explicit key set.
No layered stack yet
Dits does not currently merge system, global, repository, environment, and command-line layers. It selects either the repository file or the global file. Older Git-like configuration examples are design material, not supported syntax.
Configuration files
| Scope | Location | Selection |
|---|---|---|
| Repository | .dits/config.toml | Default while inside a repository |
| Global | <platform config directory>/dits/config.toml | Pass --global |
There is no system or worktree level. Inside a repository, an unqualified operation reads only .dits/config.toml. Outside a repository, keyed operations require --global; a bare list uses the global file.
Command
dits config [OPTIONS] [KEY] [VALUE]
Options:
--global Use the global file
-l, --list List public values from the selected file
--unset Remove an optional key
-h, --help Show command help# Repository configuration
dits config chunking.target_size 128KB
dits config chunking.target_size
dits config --list
# Global configuration
dits config --global telemetry.enabled false
dits config --global --list
# Optional identity fields can be removed
dits config --global --unset user.emailFlags such as --local, --system, --edit, --show-origin, and top-level -c overrides do not exist.
Accepted keys
| Key | Default | Current effect |
|---|---|---|
| user.name | unset | Stored preference; commits do not read it yet |
| user.email | unset | Stored preference; commits do not read it yet |
| core.default_branch | main | Stored preference; repository init still uses main |
| core.verbose | false | Stored preference; not a global verbosity flag |
| chunking.target_size | 64KB | Repository-local target chunk size |
| chunking.min_size | 16KB | Repository-local minimum chunk size |
| chunking.max_size | 256KB | Repository-local maximum chunk size |
| telemetry.enabled | false | Global opt-in telemetry switch |
Boolean values are true or false. Chunk sizes accept raw bytes or B, KB, MB, and GB suffixes. Keep min_size <= target_size <= max_size; the current parser does not validate that relationship.
Commit identity is environment-based
Setting
user.name or user.email does not currently change commit authors. Use DITS_AUTHOR_NAME and DITS_AUTHOR_EMAIL until configuration-backed identity is wired up.TOML format
[user]
name = "Jane Editor"
email = "jane@example.com"
[core]
default_branch = "main"
verbose = false
[chunking]
target_size = 65536
min_size = 16384
max_size = 262144
[telemetry]
enabled = false
last_sent = 0Unknown keys passed to dits config are rejected. Remotes are separate repository metadata in .dits/remotes and are managed by dits remote.
Malformed files fail closed
A malformed repository TOML file prevents that repository from opening and is not rewritten. A malformed global file disables telemetry for unrelated commands; telemetry status, enable, and disable fail until you repair the TOML explicitly.