diff options
Diffstat (limited to 'src/vycli.ml')
-rw-r--r-- | src/vycli.ml | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/vycli.ml b/src/vycli.ml index f793ae0..75e92b5 100644 --- a/src/vycli.ml +++ b/src/vycli.ml @@ -1,8 +1,8 @@ -open Client.Vyconf_client +open Vyconfd_client.Vyconf_client open Vyconf_connect.Vyconf_pbt type op_t = - | OpStatus + | OpPrompt | OpSetupSession | OpTeardownSession | OpShowConfig @@ -35,7 +35,7 @@ let args = [ ("--exists", Arg.Unit (fun () -> op := Some OpExists), "Check if specified path exists"); ("--list-children", Arg.Unit (fun () -> op := Some OpListChildren), "List children of the node at the specified path"); ("--show-config", Arg.Unit (fun () -> op := Some OpShowConfig), "Show the configuration at the specified path"); - ("--status", Arg.Unit (fun () -> op := Some OpStatus), "Send a status/keepalive message"); + ("--prompt", Arg.Unit (fun () -> op := Some OpPrompt), "Send a status/keepalive message"); ("--validate", Arg.Unit (fun () -> op := Some OpValidate), "Validate path"); ("--reload-reftree", Arg.Unit (fun () -> op := Some OpReloadReftree), "Reload reference tree"); ] @@ -53,14 +53,14 @@ let output_format_of_string s = | _ -> failwith (Printf.sprintf "Unknown output format %s, should be plain or json" s) let main socket op path out_format config_format = - let%lwt client = Client.Vyconf_client.create ~token:!token socket out_format config_format in + let%lwt client = create ~token:!token socket out_format config_format in let%lwt result = match op with | None -> Error "Operation required" |> Lwt.return | Some o -> begin match o with - | OpStatus -> - let%lwt resp = get_status client in + | OpPrompt -> + let%lwt resp = prompt client in begin match resp.status with | Success -> Ok "" |> Lwt.return |