From ccc0297b5acb5a375cebfa7868dd9b891462fe03 Mon Sep 17 00:00:00 2001 From: Fintan Halpenny Date: Thu, 24 Oct 2024 09:43:17 +0100 Subject: [PATCH] cli: test deletion via `git push -d` Ensure that remote branches can be delete via the `-d` flag. This includes the fact that one can delete the `refs/heads/patches` branches, as long as they are owned by the current operator. --- radicle-cli/examples/git/git-push-delete.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/radicle-cli/examples/git/git-push-delete.md b/radicle-cli/examples/git/git-push-delete.md index 9ca29cdf..0d4edb5e 100644 --- a/radicle-cli/examples/git/git-push-delete.md +++ b/radicle-cli/examples/git/git-push-delete.md @@ -18,3 +18,18 @@ $ git ls-remote rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6MknSLrJoTcukLrE435hVNQT4JU ddcc1f164eacfd7dba41da9bff3261da3ee79fd3 refs/heads/alice/2 f2de534b5e81d7c6e2dcaf58c3dd91573c0a0354 refs/heads/master ``` + +``` (stderr) RAD_SOCKET=/dev/null +$ git checkout alice/2 +Switched to a new branch 'alice/2' +$ git push rad HEAD:refs/patches +✓ Patch bb9b0d5b8de8d5e2a4cba45f02bd35b3e2678fbe opened +To [..] + * [new reference] HEAD -> refs/patches +``` + +``` (stderr) RAD_SOCKET=/dev/null +$ git push rad alice/2 -d +To rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6MknSLrJoTcukLrE435hVNQT4JUhbvWLX4kUzqkEStBU8Vi + - [deleted] alice/2 +```