about summary refs log tree commit diff
path: root/nixpkgs/pkgs/by-name/do/docfd/package.nix
blob: 8baa36826a70eba49a54a02b293810b1fdaa80e6 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
{ lib
, ocamlPackages
, fetchFromGitHub
, python3
, dune_3
}:

ocamlPackages.buildDunePackage rec {
  pname = "docfd";
  version = "3.0.0";

  minimalOCamlVersion = "5.1";

  src = fetchFromGitHub {
    owner = "darrenldl";
    repo = "docfd";
    rev = version;
    hash = "sha256-pJ5LlOfC+9NRfY7ng9LAxEnjr+mtJmhRNTo9Im6Lkbo=";
  };

  nativeBuildInputs = [ python3 dune_3 ];
  buildInputs = with ocamlPackages; [
    cmdliner
    containers-data
    digestif
    domainslib
    eio_main
    lwd
    nottui
    notty
    ocolor
    oseq
    spelll
    timedesc
    yojson
  ];

  meta = with lib; {
    description = "TUI multiline fuzzy document finder";
    longDescription = ''
      Think interactive grep for both text and other document files, but
      word/token based instead of regex and line based, so you can search
      across lines easily. Aims to provide good UX via integration with
      common text editors and other file viewers.
      Optional dependencies:
        fzf - for fuzzy file picker with "docfd ?".
        poppler_utils - for pdf search.
        pandoc - for .epub, .odt, .docx, .fb2, .ipynb, .html, & .htm files.
    '';
    homepage = "https://github.com/darrenldl/docfd";
    license = licenses.mit;
    maintainers = with maintainers; [ chewblacka ];
    platforms = platforms.all;
    mainProgram = "docfd";
  };
}