]> git.scottworley.com Git - paperdoorknob/blame_incremental - default.nix
Contemplate generating LaTeX directly
[paperdoorknob] / default.nix
... / ...
CommitLineData
1{ pkgs ? import <nixpkgs> { }, lint ? false }:
2pkgs.python3Packages.callPackage ({ lib, buildPythonPackage, makeWrapper
3 , autopep8, mypy, pylint, beautifulsoup4, requests, requests-cache
4 , texliveBasic, types-beautifulsoup4, types-requests, xdg-base-dirs
5 , pandoc-cli }:
6 buildPythonPackage rec {
7 pname = "paperdoorknob";
8 version = "0.0.1";
9 src = lib.cleanSource ./.;
10 nativeBuildInputs = [ makeWrapper ];
11 propagatedBuildInputs =
12 [ beautifulsoup4 requests requests-cache xdg-base-dirs ];
13 nativeCheckInputs =
14 [ mypy pandoc-cli texliveBasic types-beautifulsoup4 types-requests ]
15 ++ lib.optionals lint [ autopep8 pylint ];
16 doCheck = true;
17 checkPhase = "./test.sh";
18 postInstall = ''
19 wrapProgram "$out/bin/paperdoorknob" \
20 --add-flags "--pandoc=${pandoc-cli}/bin/pandoc" \
21
22 '';
23 meta = {
24 description = "A polite glowfic → printable book scraper.";
25 homepage = "https://git.scottworley.com/paperdoorknob";
26 license = pkgs.lib.licenses.gpl3;
27 maintainers = with pkgs.lib.maintainers; [ chkno ];
28 };
29 }) { inherit (pkgs.haskellPackages) pandoc-cli; }