From 98f7dde49951062c16f260467f4a421c2b2ca0a3 Mon Sep 17 00:00:00 2001 From: "Danilo M." Date: Fri, 30 Oct 2026 17:44:35 +0100 Subject: Add repo move: refile a public repo under another section There was no way to change a repo's cgit section short of deleting and recreating it or hand-editing cgitrc, which gitctl exists to prevent. The helper gains move-repo, built from the existing pair: the block's repo.* lines (desc included) are lifted out, remove_repo_block drops them, insert_repo_block files them at the end of the target section's span, so spacing follows the same rules as add and delete. It refuses a repo not in cgit and a missing section, and is a no-op when the repo is already there. The client's repo move ensures the section exists first. Self-tests cover the block move, the file round trip and both refusals. Co-Authored-By: Claude Opus 5.5 --- skills/gitctl/SKILL.md | 2 ++ 1 file changed, 2 insertions(+) (limited to 'skills') diff --git a/skills/gitctl/SKILL.md b/skills/gitctl/SKILL.md index 726ce33..674af0d 100644 --- a/skills/gitctl/SKILL.md +++ b/skills/gitctl/SKILL.md @@ -17,6 +17,8 @@ setup" and "Client install") rather than guessing. ## When to use - User wants a NEW repo on the server -> `gitctl repo create` +- MOVE a public repo to another cgit section -> `gitctl repo move --section ` + (creates the section if missing; cgitrc only, idempotent) - DELETE a repo from the server -> `gitctl repo delete` (destructive, always confirms) - List every repo (public AND private) -> `gitctl repo list` - List/add cgit sections (categories) -> `gitctl sections list|add` -- cgit v1.2.3