summary refs log tree commit diff
path: root/pkgs/applications/misc/rxvt_unicode/wrapper.nix
blob: de37327fbeadfbdca0bb88e351b409771f7d61c7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
{ stdenv, symlinkJoin, rxvt_unicode, makeWrapper, plugins }:

let
  rxvt = rxvt_unicode.override {
    perlSupport = true;
  };
  rxvt_name = builtins.parseDrvName rxvt.name;

in symlinkJoin {
  name = "${rxvt_name.name}-with-plugins-${rxvt_name.version}";

  paths = [ rxvt ] ++ plugins;

  buildInputs = [ makeWrapper ];

  postBuild = ''
    wrapProgram $out/bin/urxvt \
      --suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl"
    wrapProgram $out/bin/urxvtd \
      --suffix-each URXVT_PERL_LIB ':' "$out/lib/urxvt/perl"
  '';
}