mirror of
https://seed.radicle.dev/rad:z3gqcJUoA1n9HaHKufZs5FCSGazv5.git
synced 2026-11-16 00:00:37 +08:00
This patch changes separates the business logic of fetching from the process of fetching itself. It does this through a sans-IO approach, where a `Fetcher` provides the necessary state to help drive a fetch forward, without performing any of the IO itself. What the `Fetcher` cares about is: - What nodes are going to be attempted to be fetched from - In what order should they be attempted - When should the fetching process be considered finished The `Fetcher` is then used in `radicle-cli` to drive forward the `sync::fetch` function, allowing it to only care about the IO.
846 B
846 B
$ rad id update --title "Add Bob" --delegate did:key:z6Mkt67GdsW7715MEfRuP4pSZxJRJh6kj6Y48WRqVv4N1tRk --repo rad:z42hL2jL4XNk6K8oHQaSWfMgCL7ji -q
c036c0d89ce26aef3ad7da402157dba16b5163b4
$ rad sync --fetch
Fetching rad:z42hL2jL4XNk6K8oHQaSWfMgCL7ji from the network, found 1 potential seed(s).
✓ Target met: 1 seed(s)
🌱 Fetched from z6MknSL…StBU8Vi
$ git commit -m "New changes" --allow-empty -q
$ git push rad master -o no-sync
$ git commit --amend -m "Neue Änderungen" --allow-empty -q
$ git push rad master -f
✓ Canonical head updated to 9170c8795d3a78f0381a0ffafb20ea69fb0f5b6b
✓ Synced with 1 node(s)
To rad://z42hL2jL4XNk6K8oHQaSWfMgCL7ji/z6MknSLrJoTcukLrE435hVNQT4JUhbvWLX4kUzqkEStBU8Vi
+ fb25886...9170c87 master -> master (forced update)