about summary refs log tree commit diff
path: root/pkgs/applications/audio/vimpc/default.nix
blob: 713f444ef1ea781d3b949697a529c2b05c14e1c1 (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
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{ lib
, stdenv
, fetchFromGitHub
, fetchpatch
, autoreconfHook
, libmpdclient
, ncurses
, pcre
, pkg-config
, taglib
, curl
}:

stdenv.mkDerivation rec {
  version = "0.09.2";
  pname = "vimpc";

  src = fetchFromGitHub {
    owner = "boysetsfrog";
    repo = "vimpc";
    rev = "v${version}";
    sha256 = "0lswzkap2nm7v5h7ppb6a64cb35rajysd09nb204rxgrkij4m6nx";
  };

  patches = [
    # Pull fix pending upstream inclusion for ncurses-6.3:
    #  https://github.com/boysetsfrog/vimpc/pull/100
    (fetchpatch {
      name = "ncurses-6.3.patch";
      url = "https://github.com/boysetsfrog/vimpc/commit/055ecdce0720fdfc9ec2528c520b6c33da36271b.patch";
      sha256 = "01p858jjxm0bf8hnk1z8h45j8c1y9i995mafa6ff3vg9vlak61pv";
    })
  ];

  nativeBuildInputs = [ autoreconfHook pkg-config ];
  buildInputs = [ libmpdclient ncurses pcre taglib curl ];

  postInstall = ''
    mkdir -p $out/etc
    cp doc/vimpcrc.example $out/etc
  '';

  meta = with lib; {
    description = "A vi/vim inspired client for the Music Player Daemon (mpd)";
    homepage = "https://github.com/boysetsfrog/vimpc";
    license = licenses.gpl3;
    platforms = platforms.unix;
    maintainers = with maintainers; [ pSub ];
    mainProgram = "vimpc";
  };
}