From c9a44982aa3e20b83c82cbe48c0b0293b5affb48 Mon Sep 17 00:00:00 2001 From: dyoshikawa Date: Thu, 25 Jun 2026 05:03:50 -0700 Subject: [PATCH] refactor(rules): align GooseRuleSettablePaths with grokcli and drop unused excludeToolDir Resolve the two non-blocking refactoring findings from the PR #2049 review: - Define GooseRuleSettablePaths via Pick, matching the grokcli/warp/deepagents fold-into-root precedent so future refactors of ToolRuleSettablePaths propagate uniformly. - Drop the now-dead excludeToolDir parameter from GooseRule.getSettablePaths; goose folds non-root rules into the root .goosehints and no longer builds a tool-dir path. Co-Authored-By: Claude Opus 4.8 (1M context) --- src/features/rules/goose-rule.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/features/rules/goose-rule.ts b/src/features/rules/goose-rule.ts index 87f96a238..5e9dd6b0a 100644 --- a/src/features/rules/goose-rule.ts +++ b/src/features/rules/goose-rule.ts @@ -9,12 +9,13 @@ import { ToolRuleFromFileParams, ToolRuleFromRulesyncRuleParams, ToolRuleParams, + ToolRuleSettablePaths, ToolRuleSettablePathsGlobal, } from "./tool-rule.js"; export type GooseRuleParams = ToolRuleParams; -export type GooseRuleSettablePaths = { +export type GooseRuleSettablePaths = Pick & { root: { relativeDirPath: string; relativeFilePath: string; @@ -48,7 +49,6 @@ export class GooseRule extends ToolRule { global, }: { global?: boolean; - excludeToolDir?: boolean; } = {}): GooseRuleSettablePaths | GooseRuleSettablePathsGlobal { if (global) { return {