Pidlock.held: def of cswap-bend-cli@0.1.0.0 Import: import cswap-bend-cli@0.1.0.0/daemon/pidlock.bend as Pidlock Lines 68-73 of cswap-bend-cli@0.1.0.0/daemon/pidlock.bend: https://jend.leeeet.dev/read.txt?path=cswap-bend-cli@0.1.0.0/daemon/pidlock.bend&start_line=68&end_line=73 import Base import cswap-bend-cli@0.1.0.0/fs.bend as Fs import cswap-bend-cli@0.1.0.0/act.bend as Act def held(-A: Type, +state_dir: String, m: Maybe<&1, File>, act: Act.of(A)) -> Act.of(A): match m: case None{}: busy_fail(A, state_dir) case Some{f}: IO.bind(Fs.Res(Unit), Fs.Res(A), claim(state_dir), c => run_held(A, state_dir, f, c, act)) Uses (10): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=File https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.bind 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=Unit https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/act.bend&name=of https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/daemon/pidlock.bend&name=busy_fail https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/daemon/pidlock.bend&name=claim https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/daemon/pidlock.bend&name=run_held https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/fs.bend&name=Res