tanmayrauth opened a new issue, #1165:
URL: https://github.com/apache/iceberg-go/issues/1165
### Feature Request / Improvement
The `iceberg branch create` and `iceberg tag create` commands landed in
#1068, but there's no symmetric `delete` yet. Once you've made a stale ref via
the CLI, the only way to clean it up is to drop into a catalog client — which
is an awkward gap.
Proposed shape:
iceberg branch delete <table-id> <branch-name> [--yes]
iceberg tag delete <table-id> <tag-name> [--yes]
Both should mirror the existing create commands in
`cmd/iceberg/branch_tag.go` — confirmation prompt unless `--yes`, error if the
ref doesn't exist, and a structured result via the `Output` interface so
`--output json` keeps working.
The underlying API is already there: `MetadataBuilder.RemoveSnapshotRef`
in `table/metadata.go` and `NewRemoveSnapshotRefUpdate` in `table/updates.go`.
A handler can mirror `runBranchCreate` and just swap in the remove call.
One thing worth flagging: `RemoveSnapshotRef` clears `currentSnapshotID`
when the removed ref is `main`, which would leave the table headless. The CLI
should reject `branch delete <table> main` before ever calling the API.
@zeroshade @laskoviymishka this can be a good-first-issue.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]