def part.found

ezx@1.11.0.0 · src/fetch/plan.bend:369

import ezx@1.11.0.0/src/fetch/plan.bend as Plan
import Base
import ezx@1.11.0.0/src/fetch/world.bend as F
import ezx@1.11.0.0/src/lock/lock.bend as L
import ezx@1.11.0.0/src/pkg/pkg.bend as K

369# the tree under BEND_LIB, read: checked the way a fetched one is, and
370# fetched when it is not there
371def part.found(
372  tree: Tree,
373  +rs: List<&2, F.Reply>,
374  +src: L.Src,
375  +fs: List<&2, K.Item>,
376  +here: String,
377  +hub: String,
378  +hash: String
379) -> Part:
380  match tree:
381    case Tree{_r, files}:
382      part.kept(good(fs, hash, cand(fs, "", files)), rs, src, fs, here, hub, hash)
383    case Gone{_why}:
384      part.fetch(rs, src, fs, here, hub, hash)

Uses (11)

Used by (1)