2019-06-16 20:59:06 +01:00
|
|
|
{ stdenv, fetchPypi, buildPythonPackage, pytest, pytestcov }:
|
2017-03-20 16:36:57 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "distro";
|
2019-02-14 07:37:14 +00:00
|
|
|
version = "1.4.0";
|
2017-03-20 16:36:57 +00:00
|
|
|
|
2019-03-14 12:09:57 +00:00
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
|
|
|
sha256 = "0mrg75w4ap7mdzyga75yaid9n8bgb345ih5mwjp3plj6v1jxwb9n";
|
|
|
|
};
|
|
|
|
|
|
|
|
# TODO: Enable more tests on NixOS (20 out of 173 are failing, 10 due to the
|
|
|
|
# missing lsb_release binary):
|
|
|
|
patches = [ ./nixos.patch ];
|
|
|
|
|
2019-02-15 11:58:47 +00:00
|
|
|
checkInputs = [ pytest pytestcov ];
|
2017-03-20 16:36:57 +00:00
|
|
|
|
|
|
|
checkPhase = ''
|
2019-02-15 11:58:47 +00:00
|
|
|
py.test
|
2017-03-20 16:36:57 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/nir0s/distro";
|
2017-03-20 16:36:57 +00:00
|
|
|
description = "Linux Distribution - a Linux OS platform information API.";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ nand0p ];
|
|
|
|
};
|
|
|
|
}
|