depot/pkgs/by-name/se/serpl/package.nix
Luke Granger-Brown 57725ef3ec Squashed 'third_party/nixpkgs/' content from commit 76612b17c0ce
git-subtree-dir: third_party/nixpkgs
git-subtree-split: 76612b17c0ce71689921ca12d9ffdc9c23ce40b2
2024-11-10 23:59:47 +00:00

41 lines
945 B
Nix

{
lib,
rustPlatform,
fetchFromGitHub,
gitUpdater,
makeWrapper,
ripgrep,
}:
let
pname = "serpl";
version = "0.3.3";
in
rustPlatform.buildRustPackage {
inherit pname version;
src = fetchFromGitHub {
owner = "yassinebridi";
repo = "serpl";
rev = version;
hash = "sha256-koD5aFqL+XVxc5Iq3reTYIHiPm0z7hAQ4K59IfbY4Hg=";
};
nativeBuildInputs = [ makeWrapper ];
cargoHash = "sha256-8XYEZQfoizVmOuh0hymzMj2UDiXNkSeHqBAWOqaMY84=";
postFixup = ''
# Serpl needs ripgrep to function properly.
wrapProgram $out/bin/serpl \
--prefix PATH : "${lib.strings.makeBinPath [ ripgrep ]}"
'';
passthru.updateScript = gitUpdater { };
meta = {
description = "Simple terminal UI for search and replace, ala VS Code";
homepage = "https://github.com/yassinebridi/serpl.git";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ NotAShelf ];
mainProgram = "serpl";
};
}