2021-08-18 13:19:15 +00:00
|
|
|
{ fetchFromGitHub, lib, rustPlatform, makeWrapper }:
|
2021-07-03 03:11:41 +00:00
|
|
|
|
|
|
|
rustPlatform.buildRustPackage rec {
|
|
|
|
pname = "helix";
|
2021-08-23 08:02:39 +00:00
|
|
|
version = "0.4.1";
|
2021-07-03 03:11:41 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "helix-editor";
|
|
|
|
repo = pname;
|
|
|
|
rev = "v${version}";
|
|
|
|
fetchSubmodules = true;
|
2021-08-23 08:02:39 +00:00
|
|
|
sha256 = "sha256-lScMHZ/pLcHkuvv8kSKnYK5AFVxyhOUMFdsu3nlDVD0=";
|
2021-07-03 03:11:41 +00:00
|
|
|
};
|
|
|
|
|
2021-08-23 08:02:39 +00:00
|
|
|
cargoSha256 = "sha256-N5vlPoYyksHEZsyia8u8qtoEBY6qsXqO9CRBFaTQmiw=";
|
2021-07-03 03:11:41 +00:00
|
|
|
|
2021-08-18 13:19:15 +00:00
|
|
|
nativeBuildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
mkdir -p $out/lib
|
|
|
|
cp -r runtime $out/lib
|
|
|
|
'';
|
|
|
|
postFixup = ''
|
|
|
|
wrapProgram $out/bin/hx --set HELIX_RUNTIME $out/lib/runtime
|
|
|
|
'';
|
2021-07-03 03:11:41 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A post-modern modal text editor";
|
|
|
|
homepage = "https://helix-editor.com";
|
|
|
|
license = licenses.mpl20;
|
2021-08-11 14:56:57 +00:00
|
|
|
mainProgram = "hx";
|
2021-07-03 03:11:41 +00:00
|
|
|
maintainers = with maintainers; [ yusdacra ];
|
|
|
|
};
|
|
|
|
}
|