From 0c072d964d4d07e69d1c0af1f3b09f9adc543571 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Sat, 28 Jun 2025 00:45:19 +0300 Subject: feat: add --delete-repo command to delete repositories from all organizations MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Added --delete-repo flag that accepts a repository name - Implemented DeleteRepo() methods in both GitHub and Codeberg API clients - Created HandleDeleteRepo handler with interactive confirmation - Shows clear status of repository across all configured organizations - Requires user to type "yes" to confirm deletion - Provides detailed feedback on success/failure for each deletion - Updated documentation and usage help 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude --- internal/cli/flags.go | 2 ++ 1 file changed, 2 insertions(+) (limited to 'internal/cli/flags.go') diff --git a/internal/cli/flags.go b/internal/cli/flags.go index aac339e..71708a2 100644 --- a/internal/cli/flags.go +++ b/internal/cli/flags.go @@ -23,6 +23,7 @@ type Flags struct { WorkDir string TestGitHubToken bool Clean bool + DeleteRepo string } // ParseFlags parses command-line flags and returns the flags struct @@ -46,6 +47,7 @@ func ParseFlags() *Flags { flag.StringVar(&f.WorkDir, "work-dir", "", "working directory for cloning repositories (default: ~/git/gitsyncer-workdir)") flag.BoolVar(&f.TestGitHubToken, "test-github-token", false, "test GitHub token authentication") flag.BoolVar(&f.Clean, "clean", false, "delete all repositories in work directory (with confirmation)") + flag.StringVar(&f.DeleteRepo, "delete-repo", "", "delete specified repository from all configured organizations (with confirmation)") flag.Parse() -- cgit v1.2.3