From fb2cb7bc0f52a634fd44e99fd8ec2ed4a43a6812 Mon Sep 17 00:00:00 2001 From: Michael Raskin <7c6f434c@mail.ru> Date: Fri, 18 Oct 2013 11:11:47 +0400 Subject: [PATCH] Adding Glances system monitoring tool --- .../interpreters/python/2.7/default.nix | 5 ++++ pkgs/top-level/python-packages.nix | 25 +++++++++++++++++++ 2 files changed, 30 insertions(+) diff --git a/pkgs/development/interpreters/python/2.7/default.nix b/pkgs/development/interpreters/python/2.7/default.nix index aea2d21fd8d6..617be4f29f13 100644 --- a/pkgs/development/interpreters/python/2.7/default.nix +++ b/pkgs/development/interpreters/python/2.7/default.nix @@ -164,6 +164,11 @@ let deps = [ ncurses ]; }; + curses_panel = buildInternalPythonModule { + moduleName = "curses_panel"; + deps = [ ncurses modules.curses ]; + }; + crypt = buildInternalPythonModule { moduleName = "crypt"; internalName = "crypt"; diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index a33103cccb84..f373b36b8168 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -2668,6 +2668,31 @@ pythonPackages = modules // import ./python-packages-generated.nix { }; }; + glances = buildPythonPackage rec { + name = "glances-${meta.version}"; + + src = fetchurl { + url = "https://github.com/nicolargo/glances/archive/v${meta.version}.tar.gz"; + sha256 = "0g2yg9qf7qgjwv13x0rx51rzhn99pcmjpb3vk0g3gmmdsqyqi0d6"; + }; + + buildInputs = [ pkgs.hddtemp ]; + + propagatedBuildInputs = [ psutil jinja2 modules.curses modules.curses_panel]; + + doCheck = false; + + preConfigure = '' + sed -i -r -e '/data_files.append[(][(](conf|etc)_path/ietc_path="etc/glances"; conf_path="etc/glances"' setup.py; + ''; + + meta = { + version = "1.7.1"; + homepage = "http://nicolargo.github.io/glances/"; + description = "Cross-platform curses-based monitoring tool"; + }; + }; + greenlet = buildPythonPackage rec { name = "greenlet-0.3.1";