From 5d0aec721d41f6d414f09837a4152e8bbd132883 Mon Sep 17 00:00:00 2001 From: Greg Gauthier Date: Fri, 6 Mar 2026 21:11:17 +0000 Subject: [PATCH] refactor(recipes): update result-refactor recipe for broader package path and error handling - Change default package_path from internal/service to internal for wider applicability. - Add instruction to output a specific message if no files are found or path does not exist in Step 1. --- .grokkit/recipes/result-refactor.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.grokkit/recipes/result-refactor.md b/.grokkit/recipes/result-refactor.md index b89656b..c83cd59 100644 --- a/.grokkit/recipes/result-refactor.md +++ b/.grokkit/recipes/result-refactor.md @@ -6,7 +6,7 @@ version: 1.0 parameters: package_path: type: string - default: internal/service + default: internal description: Package to refactor dry_run: type: bool @@ -33,6 +33,7 @@ Refactors all error handling in the target package to use the new Result[T] patt ### Step 1: Discover files **Objective:** Find every file that needs changing. **Instructions:** Recursively scan `{{.package_path}}` for `.go` files containing `if err != nil`. +If no files are found or the path does not exist, output exactly: "No files found matching the criteria." **Expected output:** A clean numbered list of full file paths (one per line). ### Step 2: Refactor each file