From cbd33011debff5fce4cf4e669d3c10f572ef72f0 Mon Sep 17 00:00:00 2001 From: Chris Ostrouchov Date: Fri, 26 Oct 2018 12:57:32 -0400 Subject: [PATCH] pythonPackages.ruamel_ordereddict: refactor move to python-modules --- .../ruamel_ordereddict/default.nix | 24 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 17 +------------ 2 files changed, 25 insertions(+), 16 deletions(-) create mode 100644 pkgs/development/python-modules/ruamel_ordereddict/default.nix diff --git a/pkgs/development/python-modules/ruamel_ordereddict/default.nix b/pkgs/development/python-modules/ruamel_ordereddict/default.nix new file mode 100644 index 000000000000..fa7bd815b686 --- /dev/null +++ b/pkgs/development/python-modules/ruamel_ordereddict/default.nix @@ -0,0 +1,24 @@ +{ stdenv +, buildPythonPackage +, fetchPypi +, isPy3k +, isPyPy +}: + +buildPythonPackage rec { + pname = "ruamel.ordereddict"; + version = "0.4.9"; + disabled = isPy3k || isPyPy; + + src = fetchPypi { + inherit pname version; + sha256 = "1xmkl8v9l9inm2pyxgc1fm5005yxm7fkd5gv74q7lj1iy5qc8n3h"; + }; + + meta = with stdenv.lib; { + description = "A version of dict that keeps keys in insertion resp. sorted order"; + homepage = https://bitbucket.org/ruamel/ordereddict; + license = licenses.mit; + }; + +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 7533bac85199..851e0e44bda4 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -3656,22 +3656,7 @@ in { ruamel_base = callPackage ../development/python-modules/ruamel_base { }; - ruamel_ordereddict = buildPythonPackage rec { - name = "ruamel.ordereddict-${version}"; - version = "0.4.9"; - disabled = isPy3k || isPyPy; - - src = pkgs.fetchurl { - url = "mirror://pypi/r/ruamel.ordereddict/${name}.tar.gz"; - sha256 = "1xmkl8v9l9inm2pyxgc1fm5005yxm7fkd5gv74q7lj1iy5qc8n3h"; - }; - - meta = { - description = "A version of dict that keeps keys in insertion resp. sorted order"; - homepage = https://bitbucket.org/ruamel/ordereddict; - license = licenses.mit; - }; - }; + ruamel_ordereddict = callPackage ../development/python-modules/ruamel_ordereddict { }; typing = callPackage ../development/python-modules/typing { };