diff options
author | Frederik Rietdijk <fridh@fridh.nl> | 2018-01-20 12:42:24 +0100 |
---|---|---|
committer | Frederik Rietdijk <fridh@fridh.nl> | 2018-01-20 12:42:24 +0100 |
commit | 29e96089491f706cb5f9e7083ef5b94422f174d3 (patch) | |
tree | 8b2343400a5af04e26f1196abc3bb961f5e6acd1 | |
parent | c0c616b81f58e649d8c1ed3452c60fd99da73ee2 (diff) | |
download | nixlib-29e96089491f706cb5f9e7083ef5b94422f174d3.tar nixlib-29e96089491f706cb5f9e7083ef5b94422f174d3.tar.gz nixlib-29e96089491f706cb5f9e7083ef5b94422f174d3.tar.bz2 nixlib-29e96089491f706cb5f9e7083ef5b94422f174d3.tar.lz nixlib-29e96089491f706cb5f9e7083ef5b94422f174d3.tar.xz nixlib-29e96089491f706cb5f9e7083ef5b94422f174d3.tar.zst nixlib-29e96089491f706cb5f9e7083ef5b94422f174d3.zip |
python.pkgs.PyLTI: move expression
-rw-r--r-- | pkgs/development/python-modules/pylti/default.nix | 51 | ||||
-rw-r--r-- | pkgs/top-level/python-packages.nix | 30 |
2 files changed, 52 insertions, 29 deletions
diff --git a/pkgs/development/python-modules/pylti/default.nix b/pkgs/development/python-modules/pylti/default.nix new file mode 100644 index 000000000000..751d9e300e51 --- /dev/null +++ b/pkgs/development/python-modules/pylti/default.nix @@ -0,0 +1,51 @@ +{ lib +, buildPythonPackage +, fetchPypi +, httplib2 +, oauth +, oauth2 +, semantic-version +, flask +, httpretty +, oauthlib +, pyflakes +, pytest_27 +, pytestcache +, pytestcov +, covCore +, pytestflakes +, pytestpep8 +, sphinx +, mock +, isPy27 +}: + +buildPythonPackage rec { + pname = "PyLTI"; + version = "0.4.1"; + + disabled = !isPy27; + + # There is no need to fix mock. https://github.com/mitodl/pylti/pull/48 + postPatch = '' + substituteInPlace setup.py --replace "mock==1.0.1" "mock" + ''; + + propagatedBuildInputs = [ httplib2 oauth oauth2 semantic-version ]; + checkInputs = [ + flask httpretty oauthlib pyflakes pytest_27 pytestcache pytestcov covCore + pytestflakes pytestpep8 sphinx mock + ]; + + src = fetchPypi { + inherit pname version; + sha256 = "076llj10j85zw3zq2gygx2pcfqi9rgcld5m4vq1iai1fk15x60fz"; + }; + + meta = { + description = "Implementation of IMS LTI interface that works with edX"; + homepage = "https://github.com/mitodl/pylti"; + license = lib.licenses.bsdOriginal; + maintainers = with lib.maintainers; [ layus ]; + }; +} \ No newline at end of file diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index a406b655c9f1..728e569c0ad3 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5621,35 +5621,7 @@ in { }; }; - PyLTI = buildPythonPackage rec { - version = "0.4.1"; - name = "PyLTI-${version}"; - - disabled = !isPy27; - - # There is no need to fix mock. https://github.com/mitodl/pylti/pull/48 - postPatch = '' - substituteInPlace setup.py --replace "mock==1.0.1" "mock" - ''; - - propagatedBuildInputs = with self; [ httplib2 oauth oauth2 semantic-version ]; - buildInputs = with self; [ - flask httpretty oauthlib pyflakes pytest_27 pytestcache pytestcov covCore - pytestflakes pytestpep8 sphinx mock - ]; - - src = pkgs.fetchurl { - url = "mirror://pypi/P/PyLTI/${name}.tar.gz"; - sha256 = "076llj10j85zw3zq2gygx2pcfqi9rgcld5m4vq1iai1fk15x60fz"; - }; - - meta = { - description = "Implementation of IMS LTI interface that works with edX"; - homepage = "https://github.com/mitodl/pylti"; - license = licenses.bsdOriginal; - maintainers = with maintainers; [ layus ]; - }; - }; + PyLTI = callPackage ../development/python-modules/pylti { }; lmdb = buildPythonPackage rec { pname = "lmdb"; |