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

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

45 lines
1.2 KiB
Nix
Raw Normal View History

2022-06-28 14:59:05 +00:00
{ lib
, buildGoModule
, fetchFromGitHub
, installShellFiles
}:
buildGoModule rec {
pname = "changelogger";
2023-12-13 17:07:53 +00:00
version = "0.6.1";
2022-06-28 14:59:05 +00:00
src = fetchFromGitHub {
owner = "MarkusFreitag";
repo = pname;
rev = "v${version}";
2023-12-13 17:07:53 +00:00
sha256 = "sha256-XDiO8r1HpdsfBKzFLnsWdxte2EqL1blPH21137fNm5M=";
2022-06-28 14:59:05 +00:00
};
2023-01-22 13:15:34 +00:00
vendorHash = "sha256-E6J+0tZriskBnXdhQOQA240c3z+laXM5honoREjHPfM=";
2022-06-28 14:59:05 +00:00
ldflags = [
"-s"
"-w"
"-X github.com/MarkusFreitag/changelogger/cmd.BuildVersion=${version}"
"-X github.com/MarkusFreitag/changelogger/cmd.BuildDate=1970-01-01T00:00:00"
];
nativeBuildInputs = [ installShellFiles ];
postInstall = ''
installShellCompletion --cmd changelogger \
--bash <($out/bin/changelogger completion bash) \
--fish <($out/bin/changelogger completion fish) \
--zsh <($out/bin/changelogger completion zsh)
'';
meta = with lib; {
description = "A tool to manage your changelog file in Markdown";
homepage = "https://github.com/MarkusFreitag/changelogger";
changelog = "https://github.com/MarkusFreitag/changelogger/blob/v${version}/CHANGELOG.md";
license = licenses.mit;
maintainers = with maintainers; [ tomsiewert ];
2023-11-27 01:17:53 +00:00
mainProgram = "changelogger";
2022-06-28 14:59:05 +00:00
};
}