Compare commits

...

1 Commits

Author SHA1 Message Date
cline-test 139f3971d0 Remove hooks toggle from Feature Settings (fully enable it to always on) 2026-01-20 09:25:10 -08:00
6 changed files with 7 additions and 40 deletions
-1
View File
@@ -110,7 +110,6 @@ func (m *Manager) ListSettings(ctx context.Context) error {
"dictationSettings",
"autoCondenseThreshold",
"autoApprovalSettings",
"hooksEnabled",
}
// Render each field using the renderer
+5 -5
View File
@@ -30,14 +30,14 @@ func isSensitiveField(fieldName string) bool {
if fieldName == "" {
return false
}
lowerName := strings.ToLower(fieldName)
for _, keyword := range sensitiveKeywords {
if strings.Contains(lowerName, keyword) {
return true
}
}
return false
}
@@ -47,14 +47,14 @@ func formatValue(val interface{}, fieldName string, censor bool) string {
if str, ok := val.(string); ok && str == "" {
return "''"
}
if censor && isSensitiveField(fieldName) {
valStr := fmt.Sprintf("%v", val)
if valStr != "" && valStr != "''" {
return "********"
}
}
return fmt.Sprintf("%v", val)
}
@@ -79,7 +79,7 @@ func RenderField(key string, value interface{}, censor bool) error {
"planActSeparateModelsSetting", "enableCheckpointsSetting",
"terminalReuseEnabled", "mcpResponsesCollapsed", "strictPlanModeEnabled",
"useAutoCondense", "yoloModeToggled", "shellIntegrationTimeout",
"terminalOutputLineLimit", "autoCondenseThreshold", "hooksEnabled":
"terminalOutputLineLimit", "autoCondenseThreshold":
fmt.Printf("%s: %s\n", camelToKebab(key), formatValue(value, key, censor))
return nil
-7
View File
@@ -8,7 +8,6 @@ import (
"github.com/cline/grpc-go/cline"
)
func ParseTaskSettings(settingsFlags []string) (*cline.Settings, *cline.Secrets, error) {
if len(settingsFlags) == 0 {
return nil, nil, nil
@@ -290,12 +289,6 @@ 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)
case "azure_identity":
val, err := parseBool(value)
if err != nil {
+1 -1
View File
@@ -108,7 +108,6 @@ message Secrets {
message Settings {
optional string lite_llm_base_url = 1;
optional bool lite_llm_use_prompt_cache = 2;
map<string, string> open_ai_headers = 3;
optional string anthropic_base_url = 4;
optional string open_router_provider_sorting = 5;
optional string aws_region = 6;
@@ -278,6 +277,7 @@ message Settings {
optional int32 open_telemetry_log_batch_timeout = 170;
optional int32 open_telemetry_log_max_queue_size = 171;
optional bool worktrees_enabled = 172;
map<string, string> open_ai_headers = 173;
}
message DictationSettings {
+1 -1
View File
@@ -264,7 +264,7 @@ const USER_SETTINGS_FIELDS = {
focusChainSettings: { default: DEFAULT_FOCUS_CHAIN_SETTINGS as FocusChainSettings },
customPrompt: { default: undefined as "compact" | undefined },
autoCondenseThreshold: { default: 0.75 as number }, // number from 0 to 1
hooksEnabled: { default: false as boolean },
hooksEnabled: { default: true as boolean },
subagentsEnabled: { default: false as boolean },
enableParallelToolCalling: { default: false as boolean },
backgroundEditEnabled: { default: false as boolean },
@@ -30,7 +30,6 @@ const FeatureSettingsSection = ({ renderSectionHeader }: FeatureSettingsSectionP
worktreesEnabled,
focusChainSettings,
multiRootSetting,
hooksEnabled,
skillsEnabled,
remoteConfigSettings,
subagentsEnabled,
@@ -411,30 +410,6 @@ const FeatureSettingsSection = ({ renderSectionHeader }: FeatureSettingsSectionP
</p>
</div>
)}
<div className="mt-2.5">
<VSCodeCheckbox
checked={hooksEnabled}
disabled={!isMacOSOrLinux()}
onChange={(e: any) => {
const checked = e.target.checked === true
updateSetting("hooksEnabled", checked)
}}>
Enable Hooks
</VSCodeCheckbox>
{!isMacOSOrLinux() ? (
<p className="text-xs mt-1" style={{ color: "var(--vscode-inputValidation-warningForeground)" }}>
Hooks are not yet supported on Windows. This feature is currently available on macOS and Linux
only.
</p>
) : (
<p className="text-xs">
<span className="text-(--vscode-errorForeground)">Experimental: </span>{" "}
<span className="text-description">
Allows execution of hooks from .clinerules/hooks/ directory.
</span>
</p>
)}
</div>
<div className="mt-2.5">
<VSCodeCheckbox
checked={skillsEnabled}