nixpkgs/pkgs/tools/misc/papis/default.nix

49 lines
1.3 KiB
Nix
Raw Normal View History

2018-02-09 04:16:36 -08:00
{ buildPythonApplication, lib, fetchFromGitHub
, argcomplete, arxiv2bib, beautifulsoup4, bibtexparser
2018-02-20 14:53:43 -08:00
, configparser, dmenu-python, habanero, papis-python-rofi
, pylibgen, prompt_toolkit, pyparser, pytest, python_magic
, pyyaml, requests, unidecode, urwid, vobject, tkinter
2018-02-09 04:16:36 -08:00
, vim
}:
buildPythonApplication rec {
pname = "papis";
2018-02-20 14:53:43 -08:00
version = "0.5.3";
2018-02-09 04:16:36 -08:00
# Missing tests on Pypi
src = fetchFromGitHub {
owner = "alejandrogallo";
repo = pname;
rev = "v${version}";
2018-02-20 14:53:43 -08:00
sha256 = "1yc4ilb7bw099pi2vwawyf8mi0n1kp87wgwgwcwc841ibq62q8ic";
2018-02-09 04:16:36 -08:00
};
postPatch = "sed -i 's/configparser>=3.0.0/# configparser>=3.0.0/' setup.py";
propagatedBuildInputs = [
argcomplete arxiv2bib beautifulsoup4 bibtexparser
2018-02-20 14:53:43 -08:00
configparser dmenu-python habanero papis-python-rofi
pylibgen prompt_toolkit pyparser python_magic pyyaml
2018-02-09 04:16:36 -08:00
requests unidecode urwid vobject tkinter
vim
];
2018-02-20 14:53:43 -08:00
checkInputs = [ pytest ];
2018-02-09 04:16:36 -08:00
# Papis tries to create the config folder under $HOME during the tests
2018-02-20 14:53:43 -08:00
checkPhase = ''
2018-02-09 04:16:36 -08:00
mkdir -p check-phase
export HOME=$(pwd)/check-phase
2018-02-20 14:53:43 -08:00
make test
make test-non-pythonic
'';
2018-02-09 04:16:36 -08:00
meta = {
description = "Powerful command-line document and bibliography manager";
homepage = http://papis.readthedocs.io/en/latest/;
license = lib.licenses.gpl3;
maintainers = [ lib.maintainers.nico202 ];
};
}