forked from NixOS/nixpkgs
/
default.nix
52 lines (44 loc) · 1.34 KB
/
default.nix
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
{ lib, fetchFromGitHub, fetchpatch
, python3, xdg_utils
}:
python3.pkgs.buildPythonApplication rec {
pname = "papis";
version = "0.7.5";
# Missing tests on Pypi
src = fetchFromGitHub {
owner = "papis";
repo = pname;
rev = "v${version}";
sha256 = "1b481sj92z9nw7gwbrpkgd4nlmqc1n73qilkc51k2r56cy1kjvss";
};
# Update click version to 7.0.0
patches = fetchpatch {
url = https://github.com/papis/papis/commit/fddb80978a37a229300b604c26e992e2dc90913f.patch;
sha256 = "0cmagfdaaml1pxhnxggifpb47z5g1p231qywnvnqpd3dm93382w1";
};
propagatedBuildInputs = with python3.pkgs; [
click requests filetype pyparsing configparser
arxiv2bib pyyaml chardet beautifulsoup4 prompt_toolkit
bibtexparser python-slugify pyparser pylibgen
habanero isbnlib
# optional dependencies
dmenu-python whoosh
];
checkInputs = (with python3.pkgs; [
pytest
]) ++ [
xdg_utils
];
# most of the downloader tests require a network connection
checkPhase = ''
HOME=$(mktemp -d) pytest papis tests --ignore tests/downloaders
'';
# FIXME: find out why 39 tests fail
doCheck = false;
meta = {
description = "Powerful command-line document and bibliography manager";
homepage = http://papis.readthedocs.io/en/latest/;
license = lib.licenses.gpl3;
maintainers = [ lib.maintainers.nico202 ];
};
}