mirror of
https://seed.radicle.dev/rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5.git
synced 2026-11-29 05:50:31 +08:00
cli: Use git push to open or update patches
This adds the ability to the git-remote-helper to open and update patches via a `git push` to the magic ref `refs/patches` and `refs/heads/patches/<patch-id>`. The main change is that we had to move away from offering the `connect` capability in the remote helper, to offering `push` and `fetch` individually. To get a feel for how this works, see the `rad-patch-via-push.md` example.
This commit is contained in:
@@ -62,6 +62,13 @@ $ rad patch show 5f0a547f7a91bf002bb0542035a647fd5af134a5
|
||||
╰─────────────────────────────────────────────────────────────────────────────────────────╯
|
||||
```
|
||||
|
||||
We can also confirm that the patch branch is in storage:
|
||||
|
||||
```
|
||||
$ git ls-remote rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk refs/heads/flux-capacitor-power
|
||||
3e674d1a1df90807e934f9ae5da2591dd6848a33 refs/heads/flux-capacitor-power
|
||||
```
|
||||
|
||||
Wait, let's add a README too! Just for fun.
|
||||
|
||||
```
|
||||
|
||||
@@ -16,7 +16,13 @@ peer. Upcoming versions of radicle will not require this step.
|
||||
```
|
||||
$ rad remote add z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk --name bob
|
||||
✓ Remote bob added with rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk
|
||||
```
|
||||
|
||||
``` (stderr)
|
||||
$ git fetch bob
|
||||
From rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk
|
||||
* [new branch] flux-capacitor-power -> bob/flux-capacitor-power
|
||||
* [new branch] master -> bob/master
|
||||
```
|
||||
|
||||
The contributor's changes are now visible to us.
|
||||
|
||||
Reference in New Issue
Block a user