2021-09-18 10:52:07 +00:00
|
|
|
{ lib, stdenv, fetchFromGitHub }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-01-17 00:15:33 +00:00
|
|
|
with lib;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "kakoune-unwrapped";
|
2022-12-17 10:02:37 +00:00
|
|
|
version = "2022.10.31";
|
2020-04-24 23:36:52 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
repo = "kakoune";
|
|
|
|
owner = "mawww";
|
|
|
|
rev = "v${version}";
|
2022-12-17 10:02:37 +00:00
|
|
|
sha256 = "sha256-vmzGaGl0KSjseSD/s6DXxvMUTmAle+Iv/ZP9llaFnXk=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
2021-09-18 10:52:07 +00:00
|
|
|
makeFlags = [ "debug=no" "PREFIX=${placeholder "out"}" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
preConfigure = ''
|
|
|
|
export version="v${version}"
|
|
|
|
'';
|
|
|
|
|
2021-02-13 14:23:35 +00:00
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
2020-12-25 13:55:36 +00:00
|
|
|
doInstallCheck = true;
|
2020-04-24 23:36:52 +00:00
|
|
|
installCheckPhase = ''
|
2020-12-25 13:55:36 +00:00
|
|
|
$out/bin/kak -ui json -e "kill 0"
|
2020-04-24 23:36:52 +00:00
|
|
|
'';
|
|
|
|
|
2020-11-03 02:18:15 +00:00
|
|
|
postInstall = ''
|
|
|
|
# make share/kak/autoload a directory, so we can use symlinkJoin with plugins
|
|
|
|
cd "$out/share/kak"
|
|
|
|
autoload_target=$(readlink autoload)
|
|
|
|
rm autoload
|
|
|
|
mkdir autoload
|
|
|
|
ln -s --relative "$autoload_target" autoload
|
|
|
|
'';
|
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
meta = {
|
|
|
|
homepage = "http://kakoune.org/";
|
|
|
|
description = "A vim inspired text editor";
|
|
|
|
license = licenses.publicDomain;
|
2021-12-19 01:06:50 +00:00
|
|
|
mainProgram = "kak";
|
2022-10-21 18:38:19 +00:00
|
|
|
maintainers = with maintainers; [ vrthra srapenne ];
|
2020-04-24 23:36:52 +00:00
|
|
|
platforms = platforms.unix;
|
|
|
|
};
|
|
|
|
}
|