From 561630399499ba2ae08cc4e674fe413c4504394f Mon Sep 17 00:00:00 2001 From: John Estabrook Date: Wed, 23 Oct 2024 18:50:46 -0500 Subject: T6718: use vycli as test case --- src/dune | 7 +++++++ src/vycli.ml | 6 +++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/dune b/src/dune index 954a055..54d2de9 100644 --- a/src/dune +++ b/src/dune @@ -26,6 +26,13 @@ (libraries vyos1x-config vyconfd_config vyconf_connect) (preprocess (pps lwt_ppx))) +(executable + (name vycli) + (public_name vycli) + (modules vycli) + (libraries client) + (preprocess (pps lwt_ppx))) + (rule (alias protoc) (mode promote) diff --git a/src/vycli.ml b/src/vycli.ml index 6c1ed0c..4310cbd 100644 --- a/src/vycli.ml +++ b/src/vycli.ml @@ -1,5 +1,5 @@ -open Vyconf_client -open Vyconf_types +open Client.Vyconf_client +open Vyconf_connect.Vyconf_pbt type op_t = | OpStatus @@ -49,7 +49,7 @@ 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 = Vyconf_client.create ~token:!token socket out_format config_format in + let%lwt client = Client.Vyconf_client.create ~token:!token socket out_format config_format in let%lwt result = match op with | None -> Error "Operation required" |> Lwt.return | Some o -> -- cgit v1.2.3