def read_w.parse
import cswap-bend-cli@0.1.0.0/setcmd.bend as Setcmdimport Base
import cswap-bend-cli@0.1.0.0/json.bend as Json
import cswap-bend-cli@0.1.0.0/act.bend as Act
39def read_w.parse(+p: String, r: Result<&2, &2, String, Json.Json>) -> Act.of(Json.Json):
40 match r:
41 case Fail{e}:
42 Act.fail(Json.Json, 1, p ++ " is not valid JSON (" ++ e ++ "); fix or delete it before changing settings")
43 case Done{j}:
44 read_w.obj(p, j)