fj tag commands + branch create/delete (close the ref-mutation gap) #132
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Task
Close
fj's ref-mutation gap: it has no git tag commands and branch support is list-only.fj taggroup:list/view <tag>/create <tag> [--target <sha>] [-m <msg>]/delete <tag> -y, backed by new thinsrc/api/helpers over/repos/{o}/{r}/tags(GET,GET .../{tag},POST,DELETE). Mirror thefj milestone/fj labelCRUD shape (typed-confirmation delete).branch-create <name> [--from <ref>]andbranch-delete <name> -y(or afj branchgroup) over/repos/{o}/{r}/branches. The read half,list_branches(src/api/repo_core.rs:246), already exists.tag listand the branch list--jsonfrom the start so they compose into changelog and cleanup pipelines.Source: rasterstate/fj#121.
Priority
p2. Branch/tag mutation is routine scripted-forge work and the one operation class where
fjhas zero coverage today (release cutting, "delete every merged feature/* branch", listing tags for changelog diffs). One notch below the p1 scripting-blockers becausefj api/raw git is a working, if defeating, fallback.Reason
fj repoexposes onlybranchesfor refs and it is list-only (src/cli/repo.rs:571); there is no branch create/delete/rename and no tag command at all (fj repo topicsis GitHub-style discovery keywords, not git tags). The only ref helper insrc/api/islist_branches;grep -rnE 'fn (create_branch|delete_branch|list_tags|create_tag|delete_tag)' src/api/returns nothing. Forgejo already serves every endpoint, so the gap is entirely at the CLI/api-helper layer. This is the read-but-not-write shape also seen in rasterstate/fj#108.Acceptance
fj tag list [--json],fj tag view <tag>,fj tag create <tag> [--target <sha>] [-m <msg>],fj tag delete <tag> -ywork against/repos/{o}/{r}/tags.fj branch-create <name> [--from <ref>]andfj branch-delete <name> -ywork against/repos/{o}/{r}/branches.src/api/helpers funnel through the existing client request path; no parallel HTTP code.-yconfirmation, consistent withfj milestone delete.src/client/integration_tests.rsfor tag CRUD and branch create/delete.cargo fmt --check,cargo clippy --all-targets --all-features -- -D warnings, andcargo test --allpass.Dependencies
None. Independent thin helpers over endpoints fj does not yet touch.
Size
L
fjhas no git tag commands and branch support is read-only (list-only), forcingfj api/raw git for ref mutation #121