MCPcopy Create free account
hub / github.com/compozy/agh / classifyConfigSetLifecycle

Function classifyConfigSetLifecycle

internal/cli/config.go:1608–1626  ·  view source on GitHub ↗
(path []string)

Source from the content-addressed store, hash-verified

1606}
1607
1608func classifyConfigSetLifecycle(path []string) (configMutationLifecycle, error) {
1609 field := strings.Join(path, ".")
1610 section := settingsSectionForConfigMutation(path)
1611 if section == "" {
1612 return restartRequiredConfigLifecycle(), nil
1613 }
1614 classification, err := settingspkg.ClassifyMutation(settingspkg.MutationDescriptor{
1615 Section: section,
1616 ChangedFields: []string{field},
1617 })
1618 if err != nil {
1619 return configMutationLifecycle{}, fmt.Errorf(
1620 "cli: classify lifecycle for config path %q: %w",
1621 field,
1622 err,
1623 )
1624 }
1625 return configLifecycleFromSettings(classification), nil
1626}
1627
1628func settingsSectionForConfigMutation(path []string) settingspkg.SectionName {
1629 if len(path) == 0 {

Callers 1

runConfigSetCommandFunction · 0.85

Tested by

no test coverage detected