nixpkgs/pkgs/tools/networking/networkmanager/dmenu/default.nix

41 lines
1.1 KiB
Nix
Raw Normal View History

{ lib, stdenv, glib, fetchFromGitHub, networkmanager, python3Packages
, gobject-introspection }:
2017-03-01 05:55:09 +01:00
let inherit (python3Packages) python pygobject3;
in stdenv.mkDerivation rec {
pname = "networkmanager_dmenu";
2020-08-23 10:38:02 +02:00
version = "1.6.0";
2017-03-01 05:55:09 +01:00
src = fetchFromGitHub {
owner = "firecat53";
repo = "networkmanager-dmenu";
rev = version;
2020-08-23 10:38:02 +02:00
sha256 = "1liidqh8c33pxyb07qyj0jkd0fdak73g9r2iwiq62vfzrpik09k0";
2017-03-01 05:55:09 +01:00
};
buildInputs = [ glib python pygobject3 gobject-introspection networkmanager python3Packages.wrapPython ];
2017-03-01 05:55:09 +01:00
dontBuild = true;
2017-03-01 05:55:09 +01:00
installPhase = ''
mkdir -p $out/bin
cp networkmanager_dmenu $out/bin/
'';
postFixup = ''
makeWrapperArgs="\
--prefix GI_TYPELIB_PATH : $GI_TYPELIB_PATH \
--prefix PYTHONPATH : \"$(toPythonPath $out):$(toPythonPath ${pygobject3})\""
wrapPythonPrograms
'';
meta = with lib; {
2017-03-01 05:55:09 +01:00
description = "Small script to manage NetworkManager connections with dmenu instead of nm-applet";
homepage = "https://github.com/firecat53/networkmanager-dmenu";
2021-01-15 10:19:50 +01:00
license = lib.licenses.mit;
maintainers = [ lib.maintainers.jensbin ];
platforms = lib.platforms.all;
2017-03-01 05:55:09 +01:00
};
}