From b2bb4644c85f055fb2cfed1e0726044c7e85d00f Mon Sep 17 00:00:00 2001 From: Clombrong Date: Thu, 29 May 2025 22:29:44 +0200 Subject: feat(portal): add the portal virtual package --- dune-project | 15 +++++++++++++++ portal.opam | 36 ++++++++++++++++++++++++++++++++++++ portal/lib/dune | 4 ++++ portal/lib/portal.mli | 5 +++++ 4 files changed, 60 insertions(+) create mode 100644 portal.opam create mode 100644 portal/lib/dune create mode 100644 portal/lib/portal.mli diff --git a/dune-project b/dune-project index 6a95ff6..f57c702 100644 --- a/dune-project +++ b/dune-project @@ -31,6 +31,21 @@ (tags (xmpp lwt))) +(package + (name portal) + (synopsis "Virtual package for XMPP portals") + (description "This library gives access to the virtual Portal module. + +In turn, the Portal module can implement various transports to XMPP (WebSockets, TCP...)") + (depends + ocaml + dune + lwt + (merlin :with-test) + (utop :with-test)) + (tags + (xmpp portal lwt))) + (package (name portal-websockets) (synopsis "WebSockets XMPP portal") diff --git a/portal.opam b/portal.opam new file mode 100644 index 0000000..8d60e7f --- /dev/null +++ b/portal.opam @@ -0,0 +1,36 @@ +# This file is generated by dune, edit dune-project instead +opam-version: "2.0" +synopsis: "Virtual package for XMPP portals" +description: """ +This library gives access to the virtual Portal module. + +In turn, the Portal module can implement various transports to XMPP (WebSockets, TCP...)""" +maintainer: ["Clombrong"] +authors: ["Clombrong"] +license: "LGPL-3.0-or-later" +tags: ["xmpp" "portal" "lwt"] +homepage: "https://forge.fsky.io/clombrong/flesh" +bug-reports: "https://forge.fsky.io/clombrong/flesh/issues" +depends: [ + "ocaml" + "dune" {>= "3.11"} + "lwt" + "merlin" {with-test} + "utop" {with-test} + "odoc" {with-doc} +] +build: [ + ["dune" "subst"] {dev} + [ + "dune" + "build" + "-p" + name + "-j" + jobs + "@install" + "@runtest" {with-test} + "@doc" {with-doc} + ] +] +dev-repo: "git+https://forge.fsky.io/clombrong/flesh.git" diff --git a/portal/lib/dune b/portal/lib/dune new file mode 100644 index 0000000..1a330b9 --- /dev/null +++ b/portal/lib/dune @@ -0,0 +1,4 @@ +(library + (public_name portal) + (virtual_modules portal) + (libraries lwt)) diff --git a/portal/lib/portal.mli b/portal/lib/portal.mli new file mode 100644 index 0000000..4432e47 --- /dev/null +++ b/portal/lib/portal.mli @@ -0,0 +1,5 @@ +val stanza_open : string -> string + +val stanza_close : string + +val connect : string -> (string Lwt_stream.t * (string option -> unit)) Lwt.t -- cgit v1.2.3