2018-12-21 05:01:13 +00:00
|
|
|
{ stdenv, buildPythonPackage, fetchPypi, python, coverage, lsof, glibcLocales }:
|
2018-10-24 15:10:04 +01:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "sh";
|
|
|
|
version = "1.12.14";
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
|
|
|
sha256 = "1z2hx357xp3v4cv44xmqp7lli3frndqpyfmpbxf7n76h7s1zaaxm";
|
|
|
|
};
|
|
|
|
|
2018-12-21 05:01:13 +00:00
|
|
|
postPatch = ''
|
|
|
|
sed -i 's#/usr/bin/env python#${python.interpreter}#' test.py
|
|
|
|
'';
|
|
|
|
|
|
|
|
checkInputs = [ coverage lsof glibcLocales ];
|
2018-10-24 15:10:04 +01:00
|
|
|
|
|
|
|
# A test needs the HOME directory to be different from $TMPDIR.
|
|
|
|
preCheck = ''
|
2018-12-21 05:01:13 +00:00
|
|
|
export LC_ALL="en_US.UTF-8"
|
2018-10-24 15:10:04 +01:00
|
|
|
HOME=$(mktemp -d)
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Python subprocess interface";
|
|
|
|
homepage = https://pypi.python.org/pypi/sh/;
|
|
|
|
license = stdenv.lib.licenses.mit;
|
|
|
|
};
|
|
|
|
}
|