config: Merge with per-value origins; configcmd: UnknownKeysNode
config.Merge(sources...) overlays explicit, ordered sources with the LoadMerged rules (LoadMerged now uses the same code) and returns the origin of every leaf, for a "config show" that says where each value is set. config.ReadFile reads one file as a mapping, Resolver.Paths() exposes the core/paths resolver (e.g. DataDir for defaults). configcmd.UnknownKeysNode checks one section of a parsed document. Needed by the yamase family's layered configuration (yamase ADR-0074). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
b7f7ba6b36
commit
185211e304
7 files changed
+262
-13
No files matched your search
@@ -179,3 +179,9 @@ func (r *Resolver) Application() core.Application { return r.app }
|
||||
// Filename returns the configuration file name this Resolver searches
|
||||
// for in every layer.
|
||||
func (r *Resolver) Filename() string { return r.filename }
|
||||
|
||||
// Paths returns the core/paths Resolver this Resolver locates its
|
||||
// directories with (same application, environment and options), for a
|
||||
// caller that also needs another category, e.g. DataDir for defaults
|
||||
// derived from it.
|
||||
func (r *Resolver) Paths() *paths.Resolver { return r.paths }
|
||||
Reference in new issue
Block a user