diff --git a/bin/dune b/bin/dune new file mode 100644 index 0000000..6f08743 --- /dev/null +++ b/bin/dune @@ -0,0 +1,5 @@ +(executable + (name main) + (public_name get-activity) + (package get-activity) + (libraries cmdliner get-activity-lib)) diff --git a/main.ml b/bin/main.ml similarity index 99% rename from main.ml rename to bin/main.ml index b8644ef..7ef8cab 100644 --- a/main.ml +++ b/bin/main.ml @@ -1,3 +1,5 @@ +open Get_activity + let ( / ) = Filename.concat let or_die = function diff --git a/main.mli b/bin/main.mli similarity index 100% rename from main.mli rename to bin/main.mli diff --git a/dune b/dune deleted file mode 100644 index b275bb5..0000000 --- a/dune +++ /dev/null @@ -1,4 +0,0 @@ -(executable - (name main) - (public_name get-activity) - (libraries cohttp cohttp-lwt cohttp-lwt-unix yojson cmdliner)) diff --git a/dune-project b/dune-project index 71f1bb5..e0482da 100644 --- a/dune-project +++ b/dune-project @@ -1,15 +1,22 @@ -(lang dune 2.3) +(lang dune 2.8) (name get-activity) (formatting disabled) (generate_opam_files true) (source (github tarides/get-activity)) (authors "talex5@gmail.com") (maintainers "Guillaume Petiot ") + (package (name get-activity) (synopsis "Collect activity as markdown") (depends (cmdliner (>= 1.1.1)) + get-activity (= :version))) + +(package + (name get-activity-lib) + (synopsis "Collect activity as markdown") + (depends cohttp cohttp-lwt cohttp-lwt-unix diff --git a/get-activity-lib.opam b/get-activity-lib.opam new file mode 100644 index 0000000..9f576d4 --- /dev/null +++ b/get-activity-lib.opam @@ -0,0 +1,31 @@ +# This file is generated by dune, edit dune-project instead +opam-version: "2.0" +synopsis: "Collect activity as markdown" +maintainer: ["Guillaume Petiot "] +authors: ["talex5@gmail.com"] +homepage: "https://github.com/tarides/get-activity" +bug-reports: "https://github.com/tarides/get-activity/issues" +depends: [ + "dune" {>= "2.8"} + "cohttp" + "cohttp-lwt" + "cohttp-lwt-unix" + "yojson" + "ocaml" {>= "4.08"} + "odoc" {with-doc} +] +build: [ + ["dune" "subst"] {dev} + [ + "dune" + "build" + "-p" + name + "-j" + jobs + "@install" + "@runtest" {with-test} + "@doc" {with-doc} + ] +] +dev-repo: "git+https://github.com/tarides/get-activity.git" diff --git a/get-activity.opam b/get-activity.opam index 4869022..a06dd1d 100644 --- a/get-activity.opam +++ b/get-activity.opam @@ -6,16 +6,14 @@ authors: ["talex5@gmail.com"] homepage: "https://github.com/tarides/get-activity" bug-reports: "https://github.com/tarides/get-activity/issues" depends: [ - "dune" {>= "2.3"} + "dune" {>= "2.8"} "cmdliner" {>= "1.1.1"} - "cohttp" - "cohttp-lwt" - "cohttp-lwt-unix" - "yojson" - "ocaml" {>= "4.08"} + "get-activity" + "=" {version} + "odoc" {with-doc} ] build: [ - ["dune" "subst"] {pinned} + ["dune" "subst"] {dev} [ "dune" "build" diff --git a/contributions.ml b/lib/contributions.ml similarity index 100% rename from contributions.ml rename to lib/contributions.ml diff --git a/contributions.mli b/lib/contributions.mli similarity index 100% rename from contributions.mli rename to lib/contributions.mli diff --git a/lib/dune b/lib/dune new file mode 100644 index 0000000..cd7ce68 --- /dev/null +++ b/lib/dune @@ -0,0 +1,4 @@ +(library + (name get_activity) + (public_name get-activity-lib) + (libraries cohttp cohttp-lwt cohttp-lwt-unix yojson)) diff --git a/graphql.ml b/lib/graphql.ml similarity index 100% rename from graphql.ml rename to lib/graphql.ml diff --git a/token.ml b/lib/token.ml similarity index 100% rename from token.ml rename to lib/token.ml diff --git a/token.mli b/lib/token.mli similarity index 100% rename from token.mli rename to lib/token.mli