Plan.plan.new: def of ezx@1.11.0.0 Import: import ezx@1.11.0.0/src/init/plan.bend as Plan Lines 227-246 of ezx@1.11.0.0/src/init/plan.bend: https://jend.leeeet.dev/read.txt?path=ezx@1.11.0.0/src/init/plan.bend&start_line=227&end_line=246 import Base import ezx@1.11.0.0/src/lock/plan.bend as P # the new project's files, once it fits. A name or entry the ledger cannot # carry, such as one holding a quote, or a description holding a newline, is # refused with no effect at all. def plan.new( ok: Bool, +name: String, +at: String, +desc: String, ignore: Maybe<&2, String>, main: Maybe<&2, String>, lib: Maybe<&2, String> ) -> P.Plan: match ok: case True{}: +text = text.of(ignore) P.Plan{P.Write{toml(), fresh(name, at)} <> ignore.put(missing(rules(name), String.lines(text)), text, files(name, at, desc, main, lib)), P.Success{}} case False{}: P.Plan{[], P.Refused{why.unfit(name, at)}} Uses (16): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String.lines https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=files https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=fresh https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=ignore.put https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=missing https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=rules https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=text.of https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=toml https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/init/plan.bend&name=why.unfit https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/lock/plan.bend&name=Effect https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/lock/plan.bend&name=Outcome https://jend.leeeet.dev/definition.txt?path=ezx@1.11.0.0/src/lock/plan.bend&name=Plan