2019-06-25 19:27:50 +01:00
|
|
|
{ lib, buildPythonPackage, fetchPypi, isPy27
|
|
|
|
, click
|
|
|
|
, ipython
|
|
|
|
, pytest
|
|
|
|
, sh
|
|
|
|
, typing
|
|
|
|
}:
|
2019-01-27 14:26:25 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "python-dotenv";
|
2019-06-25 19:27:50 +01:00
|
|
|
version = "0.10.3";
|
2019-01-27 14:26:25 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2019-06-25 19:27:50 +01:00
|
|
|
sha256 = "0i25gh8wi87l4g0iflp81rlgmps4cdmp90hwypalp7gcbwfxfmzi";
|
2019-01-27 14:26:25 +00:00
|
|
|
};
|
|
|
|
|
2019-06-25 19:27:50 +01:00
|
|
|
propagatedBuildInputs = [ click ] ++ lib.optionals isPy27 [ typing ];
|
|
|
|
|
|
|
|
checkInputs = [ ipython pytest sh ];
|
|
|
|
|
|
|
|
# cli tests are impure
|
|
|
|
checkPhase = ''
|
|
|
|
pytest tests/ -k 'not cli'
|
|
|
|
'';
|
2019-01-27 14:26:25 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Add .env support to your django/flask apps in development and deployments";
|
|
|
|
homepage = https://github.com/theskumar/python-dotenv;
|
|
|
|
license = licenses.bsdOriginal;
|
|
|
|
maintainers = with maintainers; [ earvstedt ];
|
|
|
|
};
|
|
|
|
}
|