From 4f25a125a7aeee62f0325ade460341a490832244 Mon Sep 17 00:00:00 2001 From: ivegotasthma Date: Mon, 12 Aug 2019 06:23:51 +0200 Subject: pythonPackages.coreapi: init at 2.3.3 --- .../development/python-modules/coreapi/default.nix | 44 ++++++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 pkgs/development/python-modules/coreapi/default.nix (limited to 'pkgs/development/python-modules/coreapi/default.nix') diff --git a/pkgs/development/python-modules/coreapi/default.nix b/pkgs/development/python-modules/coreapi/default.nix new file mode 100644 index 00000000000..0bbaa0b1b51 --- /dev/null +++ b/pkgs/development/python-modules/coreapi/default.nix @@ -0,0 +1,44 @@ +{ + stdenv, + fetchFromGitHub, + buildPythonPackage, + django, + coreschema, + itypes, + uritemplate, + requests, + pytest, +}: + +buildPythonPackage rec { + pname = "coreapi"; + version = "2.3.3"; + + src = fetchFromGitHub { + repo = "python-client"; + owner = "core-api"; + rev = version; + sha256 = "1c6chm3q3hyn8fmjv23qgc79ai1kr3xvrrkp4clbqkssn10k7mcw"; + }; + + propagatedBuildInputs = [ + django + coreschema + itypes + uritemplate + requests + ]; + + checkInputs = [ pytest ]; + checkPhase = '' + mv coreapi coreapi.hidden + pytest tests + ''; + + meta = with stdenv.lib; { + description = "Python client library for Core API"; + homepage = https://github.com/core-api/python-client; + license = licenses.bsd3; + maintainers = with maintainers; [ ivegotasthma ]; + }; +} -- cgit 1.4.1 From cecfde44e6f68395abb2fef79cfb84d153f0296e Mon Sep 17 00:00:00 2001 From: ivegotasthma Date: Mon, 12 Aug 2019 21:53:25 +0200 Subject: pythonPackages.drf-yasg: init at 1.16.1 --- .../development/python-modules/coreapi/default.nix | 4 +-- .../python-modules/coreschema/default.nix | 4 +-- .../python-modules/drf-yasg/default.nix | 40 ++++++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 ++ 4 files changed, 46 insertions(+), 4 deletions(-) create mode 100644 pkgs/development/python-modules/drf-yasg/default.nix (limited to 'pkgs/development/python-modules/coreapi/default.nix') diff --git a/pkgs/development/python-modules/coreapi/default.nix b/pkgs/development/python-modules/coreapi/default.nix index 0bbaa0b1b51..216d1ee6985 100644 --- a/pkgs/development/python-modules/coreapi/default.nix +++ b/pkgs/development/python-modules/coreapi/default.nix @@ -31,8 +31,8 @@ buildPythonPackage rec { checkInputs = [ pytest ]; checkPhase = '' - mv coreapi coreapi.hidden - pytest tests + cd ./tests + pytest ''; meta = with stdenv.lib; { diff --git a/pkgs/development/python-modules/coreschema/default.nix b/pkgs/development/python-modules/coreschema/default.nix index ba836f78a6e..949fa31df95 100644 --- a/pkgs/development/python-modules/coreschema/default.nix +++ b/pkgs/development/python-modules/coreschema/default.nix @@ -21,8 +21,8 @@ buildPythonPackage rec { checkInputs = [ pytest ]; checkPhase = '' - mv coreschema coreschema.hidden - pytest tests + cd ./tests + pytest ''; meta = with stdenv.lib; { diff --git a/pkgs/development/python-modules/drf-yasg/default.nix b/pkgs/development/python-modules/drf-yasg/default.nix new file mode 100644 index 00000000000..707b1e5bc6e --- /dev/null +++ b/pkgs/development/python-modules/drf-yasg/default.nix @@ -0,0 +1,40 @@ +{ + stdenv, + buildPythonPackage, + fetchPypi, + inflection, + ruamel_yaml, + setuptools_scm, + six, + coreapi, + djangorestframework, +}: + +buildPythonPackage rec { + pname = "drf-yasg"; + version = "1.16.1"; + + src = fetchPypi { + inherit pname version; + sha256 = "0ri5h5xsacm99c6gvb4ldwisbqgiv2vq8qbn7vrh6vplzlpyvzb8"; + }; + + nativeBuildInputs = [ + setuptools_scm + ]; + + propagatedBuildInputs = [ + six + inflection + ruamel_yaml + coreapi + djangorestframework + ]; + + meta = with stdenv.lib; { + description = "Generation of Swagger/OpenAPI schemas for Django REST Framework"; + homepage = https://github.com/axnsan12/drf-yasg; + maintainers = with maintainers; [ ivegotasthma ]; + license = licenses.bsd3; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index c6f073711c7..d3ee05a8b25 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2168,6 +2168,8 @@ in { urllib3 = callPackage ../development/python-modules/urllib3 {}; + drf-yasg = callPackage ../development/python-modules/drf-yasg { }; + dropbox = callPackage ../development/python-modules/dropbox {}; drms = callPackage ../development/python-modules/drms { }; -- cgit 1.4.1