Files
nixpkgs/pkgs/by-name/he/hexpatch/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

58 lines
1.4 KiB
Nix

{
lib,
fetchFromGitHub,
rustPlatform,
cmake,
python3,
versionCheckHook,
nix-update-script,
}:
rustPlatform.buildRustPackage rec {
pname = "hexpatch";
version = "1.12.4";
src = fetchFromGitHub {
owner = "Etto48";
repo = "HexPatch";
tag = "v${version}";
hash = "sha256-ThHRf3zLNpOiIpB7drLqMBdyRl6MqW45oFpz44uBwsY=";
};
cargoHash = "sha256-kMLLtrXjduQ2nyiNtiZOhlEfADhn1IKysF29WO6R8CE=";
nativeBuildInputs = [
cmake
python3
];
postFixup = ''
ln -s $out/bin/hex-patch $out/bin/hexpatch
'';
nativeInstallCheckInputs = [
versionCheckHook
];
versionCheckProgramArg = "--version";
doInstallCheck = true;
passthru = {
updateScript = nix-update-script { };
};
meta = {
description = "Binary patcher and editor written in Rust with a terminal user interface";
longDescription = ''
HexPatch is a binary patcher and editor with a terminal user interface (TUI),
capable of disassembling instructions and assembling patches. It supports a
variety of architectures and file formats, and can edit remote files
via SSH.
'';
homepage = "https://etto48.github.io/HexPatch/";
changelog = "https://github.com/Etto48/HexPatch/releases/tag/v${version}";
license = lib.licenses.mit;
maintainers = with lib.maintainers; [ ratcornu ];
mainProgram = "hexpatch";
};
}