config/packages/apps/neovim-gtk/default.nix

30 lines
766 B
Nix
Raw Permalink Normal View History

2022-02-05 21:42:36 +02:00
{ rustPackages, fetchFromGitHub,
pkg-config, gnused,
gtk3, glib, cairo, pango
}:
rustPackages.rustPlatform.buildRustPackage {
name = "neovim-gtk-nightly";
src = fetchFromGitHub {
owner = "daa84";
repo = "neovim-gtk";
rev = "c03649276ee47caa9bc7beb68f6c800b8c97651a";
sha256 = "sha256-dqJACgCXHWaRwvGxnYDSTvhbyrUarw2o9yRxjj41Auw=";
};
cargoSha256 = "sha256-hcD+kWmtIQXXm1LisHwj24ttmxJxQ9GmJNezAztZR4c=";
nativeBuildInputs = [ pkg-config gnused ];
buildInputs = [
gtk3
glib
cairo
pango
];
patches = [
./build-noforce.patch
./popup-huge-padding.patch
];
buildPhase = "make install PREFIX=$out";
installPhase = ''
sed -i 's/Name=NeovimGtk/Name=Neovim GTK/g' $out/share/applications/*.desktop
'';
}