2016-09-26 11:09:25 +02:00
|
|
|
{ stdenv, fetchFromGitHub, pythonPackages }:
|
2015-03-19 07:09:58 +01:00
|
|
|
|
2017-07-26 05:21:27 +02:00
|
|
|
let
|
|
|
|
inherit (pythonPackages) python;
|
|
|
|
pname = "honcho";
|
|
|
|
|
|
|
|
in
|
|
|
|
|
|
|
|
pythonPackages.buildPythonApplication rec {
|
|
|
|
name = "${pname}-${version}";
|
|
|
|
version = "1.0.1";
|
2015-03-19 07:09:58 +01:00
|
|
|
namePrefix = "";
|
|
|
|
|
2016-09-06 20:58:42 +02:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "nickstenning";
|
|
|
|
repo = "honcho";
|
|
|
|
rev = "v${version}";
|
2017-07-26 05:21:27 +02:00
|
|
|
sha256 = "11bd87474qpif20xdcn0ra1idj5k16ka51i658wfpxwc6nzsn92b";
|
2015-03-19 07:09:58 +01:00
|
|
|
};
|
|
|
|
|
2017-07-26 05:21:27 +02:00
|
|
|
buildInputs = with pythonPackages; [ jinja2 pytest mock coverage ];
|
|
|
|
|
|
|
|
buildPhase = ''
|
|
|
|
${python.interpreter} setup.py build
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p "$out/lib/${python.libPrefix}/site-packages"
|
|
|
|
|
|
|
|
export PYTHONPATH="$out/lib/${python.libPrefix}/site-packages:$PYTHONPATH"
|
|
|
|
|
|
|
|
${python}/bin/${python.executable} setup.py install \
|
|
|
|
--install-lib=$out/lib/${python.libPrefix}/site-packages \
|
|
|
|
--prefix="$out"
|
|
|
|
'';
|
|
|
|
|
2015-03-19 07:09:58 +01:00
|
|
|
checkPhase = ''
|
|
|
|
runHook preCheck
|
2017-07-26 05:21:27 +02:00
|
|
|
PATH=$out/bin:$PATH coverage run -m pytest
|
2015-03-19 07:09:58 +01:00
|
|
|
runHook postCheck
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2015-04-28 10:54:58 +02:00
|
|
|
description = "A Python clone of Foreman, a tool for managing Procfile-based applications";
|
2015-03-19 07:09:58 +01:00
|
|
|
license = licenses.mit;
|
2015-04-20 14:20:03 +02:00
|
|
|
homepage = https://github.com/nickstenning/honcho;
|
2015-03-19 07:09:58 +01:00
|
|
|
maintainers = with maintainers; [ benley ];
|
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
2017-07-26 05:21:27 +02:00
|
|
|
}
|