Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / powerline / default.nix
blob5516db843bcfcf2ad1964fcf4a52a282244e724b
1 { lib
2 , fetchFromGitHub
3 , buildPythonPackage
4 , socat
5 , psutil
6 , python-hglib
7 , pygit2
8 , pyuv
9 , i3ipc
10 , stdenv
13 # TODO: bzr support is missing because nixpkgs switched to `breezy`
15 buildPythonPackage rec {
16   version  = "2.8.3";
17   pname = "powerline";
18   format = "setuptools";
20   src = fetchFromGitHub {
21     owner = pname;
22     repo = pname;
23     rev = "refs/tags/${version}";
24     hash = "sha256-UIx9/IZg6Wv596wHzQb0CO6zwmQXUaFEPKBojo2LXmA=";
25   };
27   propagatedBuildInputs = [
28     socat
29     psutil
30     python-hglib
31     pygit2
32     pyuv
33   ] ++ lib.optionals (!stdenv.isDarwin) [ i3ipc ];
35   # tests are travis-specific
36   doCheck = false;
38   postInstall = ''
39     install -dm755 "$out/share/fonts/OTF/"
40     install -dm755 "$out/etc/fonts/conf.d"
41     install -m644 "font/PowerlineSymbols.otf" "$out/share/fonts/OTF/PowerlineSymbols.otf"
42     install -m644 "font/10-powerline-symbols.conf" "$out/etc/fonts/conf.d/10-powerline-symbols.conf"
44     install -dm755 "$out/share/fish/vendor_functions.d"
45     install -m644 "powerline/bindings/fish/powerline-setup.fish" "$out/share/fish/vendor_functions.d/powerline-setup.fish"
47     cp -ra powerline/bindings/{bash,shell,tcsh,tmux,vim,zsh} $out/share/
48     rm $out/share/*/*.py
49   '';
51   meta = {
52     homepage    = "https://github.com/powerline/powerline";
53     description = "The ultimate statusline/prompt utility";
54     license     = lib.licenses.mit;
55   };