def joint.at
ezx@1.11.0.0 · src/ws/run.bend:153
import ezx@1.11.0.0/src/ws/run.bend as Run
import Base
import ezx@1.11.0.0/src/ledger/render.bend as Rend
import ezx@1.11.0.0/src/ws/workspace.bend as W
import ezx@1.11.0.0/src/ws/joint.bend as J
import ezx@1.11.0.0/src/ws/up.bend as U
import ezx@1.11.0.0/src/pkg/pkg.bend as K
153
154def joint.at(
155 jj: J.Joint,
156 +text: String,
157 +spec: W.Spec,
158 +fs: List<&2, J.Found>,
159 +files: List<&2, K.Source>,
160 +lock: String
161) -> IO(Planned):
162 match jj:
163 case J.Lone{}:
164 IO.pure(Planned, Planned{Some{text}, U.Alone{}, []})
165 case J.Clash{why}:
166 IO.die(Planned, 1, why)
167 case J.Joint{+mm}:
168 IO.pure(Planned, Planned{Some{Rend.show(mm)}, U.Back{text, spec, fs, lock},
169 J.seeds(J.Joint{mm}, files)})