diff options
author | Charles Strahan <charles@cstrahan.com> | 2017-07-25 23:21:27 -0400 |
---|---|---|
committer | Charles Strahan <charles@cstrahan.com> | 2017-07-25 23:22:01 -0400 |
commit | cadb42fafb40175896279122e80d4196a06f6601 (patch) | |
tree | 81d3d59abcedf9714a29384a35fd75d807ad4c8f /pkgs/tools/system/honcho/default.nix | |
parent | 69c2c997e0b5eba3271e2895ce83378bc28b097b (diff) | |
download | nixpkgs-cadb42fafb40175896279122e80d4196a06f6601.tar nixpkgs-cadb42fafb40175896279122e80d4196a06f6601.tar.gz nixpkgs-cadb42fafb40175896279122e80d4196a06f6601.tar.bz2 nixpkgs-cadb42fafb40175896279122e80d4196a06f6601.tar.lz nixpkgs-cadb42fafb40175896279122e80d4196a06f6601.tar.xz nixpkgs-cadb42fafb40175896279122e80d4196a06f6601.tar.zst nixpkgs-cadb42fafb40175896279122e80d4196a06f6601.zip |
honcho: 0.6.6 -> 1.0.1
Diffstat (limited to 'pkgs/tools/system/honcho/default.nix')
-rw-r--r-- | pkgs/tools/system/honcho/default.nix | 44 |
1 files changed, 28 insertions, 16 deletions
diff --git a/pkgs/tools/system/honcho/default.nix b/pkgs/tools/system/honcho/default.nix index 6946862422b..d42a6488c7f 100644 --- a/pkgs/tools/system/honcho/default.nix +++ b/pkgs/tools/system/honcho/default.nix @@ -1,26 +1,45 @@ { stdenv, fetchFromGitHub, pythonPackages }: -let honcho = pythonPackages.buildPythonApplication rec { - name = "honcho-${version}"; - version = "0.6.6"; +let + inherit (pythonPackages) python; + pname = "honcho"; + +in + +pythonPackages.buildPythonApplication rec { + name = "${pname}-${version}"; + version = "1.0.1"; namePrefix = ""; src = fetchFromGitHub { owner = "nickstenning"; repo = "honcho"; rev = "v${version}"; - sha256 = "0lawwcyrrsd9z9jcr94qn1yabl9bzc529jkpc51jq720fhdlfcr0"; + sha256 = "11bd87474qpif20xdcn0ra1idj5k16ka51i658wfpxwc6nzsn92b"; }; - buildInputs = with pythonPackages; [ nose mock jinja2 ]; + 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" + ''; + checkPhase = '' runHook preCheck - nosetests + PATH=$out/bin:$PATH coverage run -m pytest runHook postCheck ''; - doCheck = false; - meta = with stdenv.lib; { description = "A Python clone of Foreman, a tool for managing Procfile-based applications"; license = licenses.mit; @@ -28,11 +47,4 @@ let honcho = pythonPackages.buildPythonApplication rec { maintainers = with maintainers; [ benley ]; platforms = platforms.unix; }; -}; - -in - -# Some of honcho's tests require that honcho be installed in the environment in -# order to work. This is a trick to build it without running tests, then pass -# it to itself as a buildInput so the tests work. -honcho.overrideDerivation (x: { buildInputs = [ honcho ]; doCheck = true; }) +} |