feat(hooks): Enable hooks in the CLI [ENG-1375] (#7948)
* feat(cli): Add hooks_enabled support to CLI settings - Add hooks_enabled field to Settings proto message (field 134) - Add hooks_enabled parsing to CLI settings parser - Enables users to toggle hooks via -s hooks_enabled=true/false flag Fixes missing CLI support for hooks that was available in the VSCode extension * feat(hooks): Enable hooks in the CLI * Add include back in after resolving merge conflict * feat(hooks): Changes as per human code review feedback. --------- Co-authored-by: NightTrek <Daniels@dual4t.com>
This commit is contained in:
1 parent
8ce7e132d2
commit
dec215cd9c
14 files changed
+66
-17
No files matched your search
@@ -110,6 +110,7 @@ func (m *Manager) ListSettings(ctx context.Context) error {
|
||||
"dictationSettings",
|
||||
"autoCondenseThreshold",
|
||||
"autoApprovalSettings",
|
||||
"hooksEnabled",
|
||||
}
|
||||
|
||||
// Render each field using the renderer
|
||||
|
||||
@@ -79,7 +79,7 @@ func RenderField(key string, value interface{}, censor bool) error {
|
||||
"planActSeparateModelsSetting", "enableCheckpointsSetting",
|
||||
"terminalReuseEnabled", "mcpResponsesCollapsed", "strictPlanModeEnabled",
|
||||
"useAutoCondense", "yoloModeToggled", "shellIntegrationTimeout",
|
||||
"terminalOutputLineLimit", "autoCondenseThreshold":
|
||||
"terminalOutputLineLimit", "autoCondenseThreshold", "hooksEnabled":
|
||||
fmt.Printf("%s: %s\n", camelToKebab(key), formatValue(value, key, censor))
|
||||
return nil
|
||||
|
||||
|
||||
@@ -290,6 +290,12 @@ func setSimpleField(settings *cline.Settings, key, value string) error {
|
||||
return err
|
||||
}
|
||||
settings.ActModeAwsBedrockCustomSelected = boolPtr(val)
|
||||
case "hooks_enabled":
|
||||
val, err := parseBool(value)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
settings.HooksEnabled = boolPtr(val)
|
||||
|
||||
// Integer fields
|
||||
case "request_timeout_ms":
|
||||
|
||||
Reference in new issue
Block a user