Prepare resolved documents and autocorrection rules

This commit is contained in:
2026-11-30 00:31:36 +00:00
parent 5c4ca20b11
commit 4e94b2157b
22 changed files with 197 additions and 335 deletions

View File

@@ -53,24 +53,19 @@ type remoteLocksCheck struct {
func inspectStableInputs(cfg *config.Config) []stableInputCheck {
items := []struct {
name string
in config.ResolvedInputFile
optional bool
derived bool
name string
in config.ResolvedInputFile
derived string
}{
{name: "speakers", in: cfg.StableInputs.SpeakersFile},
{name: "autocorrect", in: cfg.StableInputs.AutocorrectFile},
{name: "players", derived: true},
{name: "autocorrect", derived: "derived from configuration"},
{name: "players", derived: "derived from canonical party"},
{name: "party", in: cfg.StableInputs.PartyFile},
{name: "spell_catalog", in: cfg.StableInputs.SpellCatalogFile, optional: true},
}
out := make([]stableInputCheck, 0, len(items))
for _, item := range items {
if item.derived {
out = append(out, stableInputCheck{Name: item.name, Path: "derived from canonical party"})
continue
}
if item.optional && strings.TrimSpace(item.in.Path) == "" {
if item.derived != "" {
out = append(out, stableInputCheck{Name: item.name, Path: item.derived})
continue
}
path, err := resolveHelperConfigRelativePath(item.in)