From b94953dbd41c3e6e371a9ba2fe97e7c7750b92a8 Mon Sep 17 00:00:00 2001 From: Jules Aguillon Date: Tue, 4 Jul 2023 15:57:37 +0200 Subject: [PATCH] odig: Init at 0.0.9 Odig is a tool for building the documentation of OCaml libraries. It is described with the recent `buildTopkgPackage` function. --- .../ocaml-modules/odig/default.nix | 25 +++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 ++ pkgs/top-level/ocaml-packages.nix | 2 ++ 3 files changed, 29 insertions(+) create mode 100644 pkgs/development/ocaml-modules/odig/default.nix diff --git a/pkgs/development/ocaml-modules/odig/default.nix b/pkgs/development/ocaml-modules/odig/default.nix new file mode 100644 index 000000000000..5ea3730c7ff4 --- /dev/null +++ b/pkgs/development/ocaml-modules/odig/default.nix @@ -0,0 +1,25 @@ +{ lib, stdenv, fetchurl, buildTopkgPackage, cmdliner, odoc, b0 }: + +buildTopkgPackage rec { + pname = "odig"; + version = "0.0.9"; + + src = fetchurl { + url = "${meta.homepage}/releases/odig-${version}.tbz"; + sha256 = "sha256-sYKvGYkxeF5FmrNQdOyMAtlsJqhlmUESi9SkPn/cjM4="; + }; + + buildInputs = [ cmdliner odoc b0 ]; + + meta = with lib; { + description = "Lookup documentation of installed OCaml packages"; + longDescription = '' + odig is a command line tool to lookup documentation of installed OCaml + packages. It shows package metadata, readmes, change logs, licenses, + cross-referenced `odoc` API documentation and manuals. + ''; + homepage = "https://erratique.ch/software/odig"; + license = licenses.isc; + maintainers = [ maintainers.Julow ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index fcd85ba8296f..c1d37972ab7a 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -16863,6 +16863,8 @@ with pkgs; ocamlformat_0_22_4 ocamlformat_0_23_0 ocamlformat_0_24_1 ocamlformat_0_25_1 ocamlformat_0_26_0; + inherit (ocamlPackages) odig; + orc = callPackage ../development/compilers/orc { }; orocos-kdl = callPackage ../development/libraries/orocos-kdl { }; diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index 649463029c94..71fc1d9a460f 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -1332,6 +1332,8 @@ let odate = callPackage ../development/ocaml-modules/odate { }; + odig = callPackage ../development/ocaml-modules/odig { }; + odoc = callPackage ../development/ocaml-modules/odoc { }; odoc-parser = callPackage ../development/ocaml-modules/odoc-parser { };