Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / ghrepo-stats / default.nix
blobc7f3c0d52cdaa7f411fb631deb7fa713092741f0
1 { lib
2 , beautifulsoup4
3 , buildPythonPackage
4 , fetchFromGitHub
5 , matplotlib
6 , pygithub
7 , pythonOlder
8 }:
10 buildPythonPackage rec {
11   pname = "ghrepo-stats";
12   version = "0.5.4";
13   format = "setuptools";
15   disabled = pythonOlder "3.8";
17   src = fetchFromGitHub {
18     owner = "mrbean-bremen";
19     repo = pname;
20     rev = "refs/tags/v${version}";
21     hash = "sha256-Mr0FM2CbdgAUF8siMjUIZvypWiPNPU9OncPiBPqK3uE=";
22   };
24   postPatch = ''
25     # https://github.com/mrbean-bremen/ghrepo-stats/pull/1
26     substituteInPlace setup.py \
27       --replace "bs4" "beautifulsoup4"
28   '';
30   propagatedBuildInputs = [
31     beautifulsoup4
32     matplotlib
33     pygithub
34   ];
36   # Module has no tests
37   doCheck = false;
39   pythonImportsCheck = [
40     "ghrepo_stats"
41   ];
43   meta = with lib; {
44     description = "Python module and CLI tool for GitHub repo statistics";
45     homepage = "https://github.com/mrbean-bremen/ghrepo-stats";
46     changelog = "https://github.com/mrbean-bremen/ghrepo-stats/blob/v${version}/CHANGES.md";
47     license = licenses.mit;
48     maintainers = with maintainers; [ fab ];
49   };