about summary refs log tree commit diff
path: root/overrides/fish/default.nix
blob: c8d8f7c8b5fe65af96f7b3034b6056cde3e7bd15 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
{ stdenv, fetchurl, autoconf, ncurses, groff, makeWrapper, pythonPackages }:

stdenv.mkDerivation rec {
  name = "fish-${version}";
  version = "2.0.0";

  buildInputs = [
    autoconf ncurses makeWrapper pythonPackages.wrapPython pythonPackages.python
  ];

  pythonPath = [ pythonPackages.curses ];

  enableParallelBuilding = true;

  preConfigure = ''
    autoconf
    sed -i 's/\<which\>/type -P/g' configure
  '';

  postFixup = ''
    wrapPythonPrograms

    sed -i 's|nroff|${groff}/bin/nroff|g' \
      "$out/share/fish/functions/__fish_print_help.fish"
  '';

  src = fetchurl {
    url = "http://fishshell.com/files/${version}/fish.tar.gz";
    sha1 = "2d28553e2ff975f8e5fed6b266f7a940493b6636";
  };
}