2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, numpy
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "haversine";
|
2021-06-06 07:54:09 +00:00
|
|
|
version = "2.3.1";
|
2021-02-05 17:12:51 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "mapado";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
2021-06-06 07:54:09 +00:00
|
|
|
sha256 = "sha256-1PXPsZd/4pN42TU0lhXWsmyX7uGP1n/xna2cVZPczB4=";
|
2021-02-05 17:12:51 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
checkInputs = [
|
|
|
|
numpy
|
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
pythonImportsCheck = [ "haversine" ];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python module the distance between 2 points on earth";
|
|
|
|
homepage = "https://github.com/mapado/haversine";
|
|
|
|
license = with licenses; [ mit ];
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|