Expand description
TOML configuration with XDG-style paths, .env files and environment overrides.
Resolution order, later wins:
built-in defaults < config file < shared .env < profile .env < environmentSecrets belong in .env (mode 0600) rather than in config.toml, which is the file
people paste into issues; config.toml can then refer to them as ${NAME} (see
crate::interpolate). There are deliberately no built-in endpoints or API keys.
Re-exports§
pub use migrate::baseline_path;pub use migrate::plan as migration_plan;pub use migrate::Change;pub use migrate::Plan;
Modules§
- migrate
eclipse config migrate— bringing a config file forward without touching what its owner chose.
Structs§
- Agent
Config - Attachments
Config [attachments]: where the pictures someone attaches are kept (#499).- BotConfig
[bots.<name>]: one named agent identity (#509).- Chain
- The routes one run will use, in order.
- CliConfig
- Terminal behaviour. Every field here is read by the CLI; a setting nothing reads is a lie in the starter config.
- Config
- Context
Policy Config [context]: how a request that no longer fits is shortened. The head (first turn) and the tail (newest turns) stay verbatim; what pays is the middle.- Dotenv
- The
.envfiles read for this profile, and what they set. - Flares
Config [flares]: what a run costs and how wide it may go (#171).- Gateway
Config [gateway]: the one long-lived process that keeps the whole thing running.- Hooks
Config [hooks]: which in-process loop hooks run, and their settings.- Init
Report - What
config initdid, so the caller can report it without re-deriving paths. - Named
Route - A route with its name attached and the route table itself stripped off, so what is left is exactly one provider’s settings.
- Plugins
Config [plugins]: where plugins live and which ones may load.- Provider
Config - Route
Config - One
[[provider.route]]: a name and a completeProviderConfig. - Sessions
Config - Setting
- One key a person can read and write:
[section] key, its default and its current value. - Skills
Config - Tools
Config - Unknown
Key - A key in a config file that no part of
Configreads. - Update
Config [update]: the notice that says a newer commit exists. It is the only request this tool makes that is neither a model call nor something the user asked for, so it has a switch.- User
Config [user]: the user model and the agent’s memory file.- Vision
Config [skills]: how much of the prompt the skills index may take.- WebConfig
- Where
- Where this process is running from — the four answers
Config::where_am_ifills in.
Enums§
- Applies
- When a changed key takes effect.
- Approval
- What the CLI does when a tool’s policy is
ask. - Chain
Source - Where a run’s chain of routes came from.
- Clear
OnExit - What an interactive exit does to the screen:
[cli] clear_on_exit. - Fetch
Html - What happens when the model asks for a tool.
How
fetchreturns an HTML response by default. - Kind
- The type a key holds, used both to validate what was typed and to say what went wrong.
- Policy
- Shell
Ask - What the shell puts to a person when its policy is
Policy::Ask. - Shell
Isolate - What a
shellcommand can reach once it runs. The mechanics are ineclipse_core::sandbox. - Track
- Which branch a source install follows:
[update] track. - Update
Check - How often the update notice asks the public repository for its latest commit.
- Vision
Mode - The three modes, spelled in the file the way a person would say them.
Constants§
- APP_DIR
- BOT_
ADAPTERS - The adapters this build can actually drive (
#509). Slice 3 addstelegram; a name that is not here is reported byproblemsrather than refused, because the declaration is still worth writing down today — the bot answers on the web and the lane arrives with slice 3. - CONFIG_
VERSION - The shape of
config.tomlthis build writes, stamped into the file asconfig_version. - DEFAULT_
ROUTE - The name
[provider]itself goes by once routes exist. - DEFAULT_
SESSION_ TTL_ HOURS - How long a dashboard login lasts before the browser has to sign in again.
- ENV_
ABOUT - One line per variable, for the manual: what it is for.
- ENV_
INTERNAL - Variables this tool sets in a child’s environment (a plugin, an MCP server, a spawned tool
call). Nobody sets these by hand, and a value in
.envwould be overwritten anyway. - ENV_
SHELL_ ONLY - Variables read before a
.envis opened, or from the process environment only. Setting one of these inside.envwould be inert, which is worse than absent: it looks like a setting. - ENV_
TEMPLATE - Every variable the shipped
.envlists, in the order it lists them, with empty values. - STARTER_
AGENT_ MD - The starter
AGENT.md, written on first install. The user is expected to edit it; the content is a shape and a set of instructions, not facts about the machine. - STARTER_
PROFILE_ CONFIG - The file a named profile starts from: an overlay, not a whole config. Only the keys a profile usually changes are here, uncommented examples included — a profile that restated every default would pin them, and then a change to the base config would stop reaching it.
- STARTER_
USER_ MD - The starter
USER.md: who the operator is. Edit it; it is the agent’s standing picture of the user, injected on every run.
Functions§
- about
- One line per key: what it does, in words a person choosing it can use.
- choices
- comment_
in_ text - Insert
# key =under[section], which is how a shipped file says “this key exists and is not in use” for a key whose off state has no spelling (a number, a colour, an explicit boolean). - config_
dir - Where
config.toml,.envand the sharedplugins/,skills/andscripts/live: the root itself. A--configelsewhere moves the file without moving the directory it is read from, which is whatconfig_pathis for. - config_
path $ECLIPSE_CONFIGor<config_dir>/config.toml.- default_
api_ session_ ttl_ hours - default_
hidden_ paths - The secrets under
$HOMEthatfsmode empties by default: what an injected command would look for first, and none of which a build needs. - dotenv_
var - The value of
KEYin a.envfile, if it has one. - ensure_
layout - Create the directories the layout names, so that
ls ~/.eclipseanswers “where does the agent’s stuff go?” without reading a document. Idempotent, and it never touches a file. - env_
about - What one variable is for, or
""— the same lookup shape assettings::about. - home_
root - The one directory everything lives in:
$ECLIPSE_HOME, or~/.eclipse. - mcp_add
- Add
[[mcp]]entry — toconfig.toml, which is the file this edits (#352). - mcp_
remove - Remove the
[[mcp]]entry calledname. Only that block goes. - mcp_
set_ disabled - Switch an entry off (or back on) in place:
disabled = trueinside its own block. - mcp_
update - Change the
[[mcp]]entry callednamein place (#517). - parse_
text - Parse config text exactly as the loader would. A writer uses this to prove what it is about to save is loadable before it replaces the user’s file.
- parse_
value - Parse one value as a person typed it.
- process_
env - profile_
dir <root>/profiles/<name>: a profile’s own config overlay,memory/,skills/,plugins/andstate/.- save_
config_ text - Write config text back with the same permissions as the starter (
0600) — the file can carryapi_key, and a config people paste into bug reports should still be readable only by them. - save_
dotenv_ var - Set
KEY=valuein a.env, creating it0600if it does not exist. An existing line for that key is replaced; every other line, comment included, is kept. Values are written raw: a.envis not TOML and the loader takes the rest of the line as the value. - seed_
context_ files - Seed the three context files in the memory directory, creating any that are missing.
- set_
in_ text - Set
pathtovaluein this config text, returning the new text. - set_
list_ in_ text - Set a list-valued key from
items—plugins.enabled = ["a", "b"]. - stamp_
version - Write
config_version = Ninto this TOML text, at the top, where the generated file puts it. - starter_
config - The shipped
config.toml: every setting this build reads, and no prose. - starter_
env - The shipped
.env: every variable, nothing set, and the dashboard token already generated. - state_
dir - Machine-written files: sessions, REPL history, locks,
install.json,update.json. Inside the root so that a backup, a move or a delete is one operation, and named for what it is rather than for who wrote it. - state_
dir_ for - State directory for a profile: the root’s own
state/for the default profile, otherwiseprofiles/<name>/state— beside that profile’s config, not inside the root’s state, so a profile is a subtree you can move or delete in one piece. - toml_
comment_ out - Comment
[section] key = …out of this TOML text, so the file falls back to the default. - toml_
set_ string - Set
[section] key = "value"in this TOML text and return the whole text back. - toml_
set_ value - Set
[section] key = <value>wherevalueis already TOML —9000,true,["a", "b"],"text"with its quotes. The line-editing rules aretoml_set_string’s. - toml_
value - The value
[section] key = ...holds in this TOML text, unquoted, if the key is set. Commented-out template lines do not count: they are documentation, not config. - unknown_
keys_ in_ file - Read one config file and report the keys in it that
cfgdoes not read. - unset_
in_ text - Comment
pathout of this config text, so the file falls back to its default. - validate_
profile_ name - Profile names become directory names, so they are held to the same alphabet as session
ids:
[A-Za-z0-9_-], 1-64 characters. - write_
starter_ config - Write the starter config, and the
.envwhere the loader will read it, with a freshly generated dashboard token (the token is never returned or printed). - write_
target - The file a config write lands in (
#571).
Type Aliases§
- EnvFn
- Environment lookup, injectable so tests never touch the process environment.