def set_ok

cswap-bend-cli@0.1.0.0 · profcmd.bend:130

import cswap-bend-cli@0.1.0.0/profcmd.bend as Profcmd
import Base
import cswap-bend-cli@0.1.0.0/json.bend as Json
import cswap-bend-cli@0.1.0.0/cmd.bend as Cmd
import cswap-bend-cli@0.1.0.0/profile.bend as P
import cswap-bend-cli@0.1.0.0/daemon/config.bend as Cfg
import cswap-bend-cli@0.1.0.0/profview.bend as PV

130def set_ok(+json: Bool, +raw: Json.Json, +name: String, +key: String, +value: String, +p: P.Prof) -> Cmd.Out:
131  match json:
132    case True{}:
133      doc([("profile", PV.prof_json(raw, Cfg.from_settings(raw), p))])
134    case False{}:
135      Cmd.ok("profile " ++ name ++ ": " ++ key ++ " = " ++ value)

Uses (12)

Used by (1)