From b28c25b8a26baeb2f95a62ca01639475835c905a Mon Sep 17 00:00:00 2001 From: Dustin Smith Date: Mon, 19 Jan 2026 21:17:40 +0700 Subject: [PATCH] fix: create plugins/ directory during install Avoids gt doctor warning about missing plugin directory on fresh install. The patrol-plugins-accessible check expects town-level plugins/ directory. --- internal/cmd/install.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/internal/cmd/install.go b/internal/cmd/install.go index 0a4c68f1..dfd895f6 100644 --- a/internal/cmd/install.go +++ b/internal/cmd/install.go @@ -228,6 +228,15 @@ func runInstall(cmd *cobra.Command, args []string) error { fmt.Printf(" %s Could not create boot directory: %v\n", style.Dim.Render("⚠"), err) } + // Create plugins directory for town-level patrol plugins. + // This avoids gt doctor warning on fresh install. + pluginsDir := filepath.Join(absPath, "plugins") + if err := os.MkdirAll(pluginsDir, 0755); err != nil { + fmt.Printf(" %s Could not create plugins directory: %v\n", style.Dim.Render("⚠"), err) + } else { + fmt.Printf(" ✓ Created plugins/\n") + } + // Create daemon.json patrol config. // This avoids gt doctor warning on fresh install. if err := config.EnsureDaemonPatrolConfig(absPath); err != nil {