nixpkgs/pkgs/tools/misc/massren/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

46 lines
1.1 KiB
Nix
Raw Normal View History

2023-01-25 12:18:16 +00:00
{ lib, buildGoModule, fetchFromGitHub, fetchpatch }:
2018-02-11 07:35:05 +00:00
2023-01-25 12:18:16 +00:00
buildGoModule rec {
pname = "massren";
2022-07-28 23:17:01 +00:00
version = "1.5.6";
2018-02-11 07:35:05 +00:00
src = fetchFromGitHub {
owner = "laurent22";
repo = "massren";
rev = "v${version}";
2023-01-25 12:18:16 +00:00
hash = "sha256-17y+vmspvZKKRRaEwzP3Zya4r/z+2aSGG6oNZiA8D64=";
2018-02-11 07:35:05 +00:00
};
2023-01-25 12:18:16 +00:00
vendorHash = null;
patches = [
# Add Go Modules support
(fetchpatch {
url = "https://github.com/laurent22/massren/commit/83df215b6e112d1ec375b08d8c44dadc5107155d.patch";
hash = "sha256-FMTmUrv6zGq11vexUirAuK3H6r78RtoipqyWoh+pzrs=";
})
];
ldflags = [ "-s" "-w" ];
preCheck =
let
skippedTests = [
# Possible error about github.com/mattn/go-sqlite3
"Test_guessEditorCommand"
"Test_processFileActions"
];
in
''
buildFlagsArray+=("-run" "[^(${builtins.concatStringsSep "|" skippedTests})]")
'';
2018-02-11 07:35:05 +00:00
meta = with lib; {
description = "Easily rename multiple files using your text editor";
license = licenses.mit;
homepage = "https://github.com/laurent22/massren";
2018-02-11 07:35:05 +00:00
maintainers = with maintainers; [ andrew-d ];
2023-11-27 01:17:53 +00:00
mainProgram = "massren";
2018-02-11 07:35:05 +00:00
};
}