nixpkgs-suyu/pkgs/development/python-modules/pymetar/default.nix

31 lines
802 B
Nix
Raw Normal View History

{ lib, python, buildPythonPackage, isPy3k, fetchPypi }:
2018-03-02 17:12:08 +01:00
buildPythonPackage rec {
pname = "pymetar";
version = "1.3";
2018-03-02 17:12:08 +01:00
2018-09-05 22:32:08 +02:00
disabled = !isPy3k;
2018-03-02 17:12:08 +01:00
src = fetchPypi {
inherit pname version;
sha256 = "sha256-zhuXOZIIzh5p0CDOsiUNTqeXDoHFcf1BPg868fc7CIg=";
2018-03-02 17:12:08 +01:00
};
2018-09-05 22:56:18 +02:00
checkPhase = ''
cd testing/smoketest
tar xzf reports.tgz
mkdir logs
patchShebangs runtests.sh
substituteInPlace runtests.sh --replace "break" "exit 1" # fail properly
export PYTHONPATH="$PYTHONPATH:$out/${python.sitePackages}"
./runtests.sh
'';
meta = with lib; {
2018-03-02 17:12:08 +01:00
description = "A command-line tool to show the weather report by a given station ID";
homepage = "https://github.com/klausman/pymetar";
2018-09-05 22:26:25 +02:00
license = licenses.gpl2Plus;
2018-03-02 17:12:08 +01:00
maintainers = with maintainers; [ erosennin ];
};
}