()
| 77 | } |
| 78 | |
| 79 | func (c *tomlToolConfig) LoadAll() map[string]ScopedConfig { |
| 80 | all := map[string]ScopedConfig{} |
| 81 | for _, scope := range []Scope{UserScope, ProjectScope} { |
| 82 | path := c.PathFor(scope) |
| 83 | if path == "" { |
| 84 | continue |
| 85 | } |
| 86 | data, _, err := loadTOML(path) |
| 87 | if err != nil { |
| 88 | continue |
| 89 | } |
| 90 | all[string(scope)] = ScopedConfig{Data: data, Path: path} |
| 91 | } |
| 92 | return all |
| 93 | } |
| 94 | |
| 95 | func (c *tomlToolConfig) Set(scope Scope, keyPath string, value any) (string, error) { |
| 96 | parts, err := Parse(keyPath) |