mirror of
https://seed.radicle.dev/rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5.git
synced 2026-11-21 18:40:39 +08:00
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.
33 lines
1.1 KiB
Markdown
33 lines
1.1 KiB
Markdown
Now, let's add a bob as a new remote:
|
|
|
|
```
|
|
$ rad remote add did:key:z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk --name bob
|
|
✓ Remote bob added with rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk
|
|
```
|
|
|
|
Now, we can see that there is a new remote in the list of remotes:
|
|
|
|
```
|
|
$ rad remote list
|
|
bob z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk (fetch)
|
|
rad (canonical upstream) (fetch)
|
|
rad z6MknSLrJoTcukLrE435hVNQT4JUhbvWLX4kUzqkEStBU8Vi (push)
|
|
rad/patches (patches upstream) (push)
|
|
```
|
|
|
|
You can see both `bob` and `rad` as remotes. The `rad` remote is our personal remote of the project.
|
|
|
|
When we're finished with the `bob` remote, we can remove it:
|
|
|
|
```
|
|
$ rad remote rm bob
|
|
✓ Remote `bob` removed
|
|
```
|
|
|
|
Now, add another time `bob` but without specify the `name`, so we should be able to fetch the node alias from our db!
|
|
|
|
```
|
|
$ rad remote add did:key:z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk
|
|
✓ Remote bob added with rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk
|
|
```
|