blob: a7bac0fd7626d9db9a2c4fc7cb95cb3190f4739c (
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
|
{ stdenv, buildPythonPackage, isPy3k, fetchFromGitHub, substituteAll
, python, utillinux, pygit2, gitMinimal, git-annex
}:
buildPythonPackage rec {
pname = "git-annex-adapter";
version = "0.2.1";
disabled = !isPy3k;
# No tests in PyPI tarball
src = fetchFromGitHub {
owner = "alpernebbi";
repo = pname;
rev = "v${version}";
sha256 = "146q1jhcfc7f96ajkhjffskkljk2xzivs5ih5clb8qx0sh7mj097";
};
patches = [
(substituteAll {
src = ./git-annex-path.patch;
gitAnnex = "${git-annex}/bin/git-annex";
})
];
checkInputs = [
gitMinimal
utillinux # `rev` is needed in tests/test_process.py
];
propagatedBuildInputs = [ pygit2 ];
checkPhase = ''
${python.interpreter} -m unittest
'';
meta = with stdenv.lib; {
homepage = https://github.com/alpernebbi/git-annex-adapter;
description = "Call git-annex commands from Python";
license = licenses.gpl3Plus;
maintainers = with maintainers; [ dotlambda ];
};
}
|