2020-04-15 13:04:47 +01:00
|
|
|
{ stdenv, lib, fetchFromGitHub, fetchpatch, libiconv, ruby ? null }:
|
2018-01-06 14:59:36 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 13:41:18 +01:00
|
|
|
pname = "mblaze";
|
2019-03-10 23:42:14 +00:00
|
|
|
version = "0.5.1";
|
2018-01-06 14:59:36 +00:00
|
|
|
|
2020-04-15 13:04:47 +01:00
|
|
|
buildInputs = [ ruby ] ++ lib.optionals stdenv.isDarwin [ libiconv ];
|
2018-01-13 11:48:37 +00:00
|
|
|
|
2018-01-06 14:59:36 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "chneukirchen";
|
|
|
|
repo = "mblaze";
|
|
|
|
rev = "v${version}";
|
2019-03-10 23:42:14 +00:00
|
|
|
sha256 = "11x548dl2jy9cmgsakqrzfdq166whhk4ja7zkiaxrapkjmkf6pbh";
|
2018-01-06 14:59:36 +00:00
|
|
|
};
|
|
|
|
|
2019-03-28 21:47:56 +00:00
|
|
|
patches = [
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://github.com/leahneukirchen/mblaze/commit/53151f4f890f302291eb8d3375dec4f8ecb66ed7.patch";
|
|
|
|
sha256 = "1mcyrh053iiyzdhgm09g5h3a77np496whnc7jr4agpk1nkbcpfxc";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
2019-10-27 13:03:25 +00:00
|
|
|
makeFlags = [ "PREFIX=$(out)" ];
|
2018-01-06 14:59:36 +00:00
|
|
|
|
2019-02-24 01:07:08 +00:00
|
|
|
postInstall = ''
|
|
|
|
install -Dm644 -t $out/share/zsh/site-functions contrib/_mblaze
|
2020-04-15 13:04:47 +01:00
|
|
|
'' + lib.optionalString (ruby != null) ''
|
|
|
|
install -Dt $out/bin contrib/msuck contrib/mblow
|
2019-02-24 01:07:08 +00:00
|
|
|
'';
|
|
|
|
|
2020-04-15 13:04:47 +01:00
|
|
|
meta = with lib; {
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/chneukirchen/mblaze";
|
2018-01-06 14:59:36 +00:00
|
|
|
description = "Unix utilities to deal with Maildir";
|
|
|
|
license = licenses.cc0;
|
|
|
|
platforms = platforms.all;
|
|
|
|
maintainers = [ maintainers.ajgrf ];
|
|
|
|
};
|
|
|
|
}
|