Expand description
Port of internal/config/config.go: global configuration management.
The Go original propagates *GlobalConfig via context.Context. Rust has
no direct equivalent of Go’s context.Context value-bag; with_context
and from_context are ported here as free functions operating on an
explicit Context newtype, deferring the real async/task-local design
decision (tokio task_local!? an explicit parameter everywhere?) to
Phase 4. See PORT_NOTES.md.
Structs§
- Context
- An explicit stand-in for Go’s
context.Contextcarrying aGlobalConfig. See the module doc comment. - Global
Config
Functions§
- find_
config_ file - Searches for a
xianyun.yaml(or, as a compatibility alias,caproni.yaml) file starting from the current directory and walking up the directory tree until it reaches either the root directory or the user’s home directory. - from_
context - with_
context