2019-02-17 16:07:27 +01:00
|
|
|
{ lib, fetchurl, stdenv, libiconv, ncurses, lua }:
|
2018-04-10 06:28:02 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "dit";
|
2020-05-21 09:38:27 +02:00
|
|
|
version = "0.7";
|
2018-04-10 06:28:02 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
2019-08-15 14:41:18 +02:00
|
|
|
url = "https://hisham.hm/dit/releases/${version}/${pname}-${version}.tar.gz";
|
2020-05-21 09:38:27 +02:00
|
|
|
sha256 = "0cmbyzqfz2qa83cg8lpjifn34wmx34c5innw485zh4vk3c0k8wlj";
|
2018-04-10 06:28:02 +02:00
|
|
|
};
|
|
|
|
|
2019-02-17 16:07:27 +01:00
|
|
|
buildInputs = [ ncurses lua ]
|
|
|
|
++ lib.optional stdenv.isDarwin libiconv;
|
2018-04-10 06:28:02 +02:00
|
|
|
|
2019-02-17 16:07:27 +01:00
|
|
|
# fix paths
|
2018-04-10 06:28:02 +02:00
|
|
|
prePatch = ''
|
|
|
|
patchShebangs tools/GenHeaders
|
|
|
|
substituteInPlace Prototypes.h --replace 'tail' "$(type -P tail)"
|
|
|
|
'';
|
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2018-04-10 06:28:02 +02:00
|
|
|
description = "A console text editor for Unix that you already know how to use";
|
2020-04-09 17:42:03 +02:00
|
|
|
homepage = "https://hisham.hm/dit/";
|
2018-04-10 06:28:02 +02:00
|
|
|
license = licenses.gpl2;
|
|
|
|
platforms = with platforms; linux;
|
|
|
|
maintainers = with maintainers; [ davidak ];
|
|
|
|
};
|
|
|
|
}
|