(path, key string)
| 320 | } |
| 321 | |
| 322 | func legacyUnsetConfig(path, key string) error { |
| 323 | cfg, err := loadConfigFile(path) |
| 324 | if err != nil { |
| 325 | return err |
| 326 | } |
| 327 | parts, err := editorconfig.Parse(key) |
| 328 | if err != nil { |
| 329 | return err |
| 330 | } |
| 331 | editorconfig.Unset(cfg, parts) |
| 332 | return writeConfigFile(path, cfg) |
| 333 | } |
| 334 | |
| 335 | // legacyApplyValue is the real implementation used by the legacy `set` path. |
| 336 | // It is kept separate from legacyUnsetConfig so the `set` and `unset` flows |
no test coverage detected