nixpkgs/pkgs/by-name/ch/changelog-d/package.nix

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

39 lines
983 B
Nix
Raw Normal View History

{
2023-11-19 11:24:10 +00:00
callPackage,
lib,
haskell,
haskellPackages,
}:
let
hsPkg = haskellPackages.changelog-d;
2023-11-19 12:17:23 +00:00
addCompletions = haskellPackages.generateOptparseApplicativeCompletions ["changelog-d"];
haskellModifications =
lib.flip lib.pipe [
addCompletions
haskell.lib.justStaticExecutables
];
mkDerivationOverrides = finalAttrs: oldAttrs: {
version = oldAttrs.version + "-git-${lib.strings.substring 0 7 oldAttrs.src.rev}";
# nix-shell ./maintainers/scripts/update.nix --argstr package changelog-d
2023-11-19 11:28:03 +00:00
passthru.updateScript = lib.getExe (callPackage ./updateScript.nix { });
# nix-build -A changelog-d.tests
passthru.tests = {
2023-11-19 11:24:10 +00:00
basic = callPackage ./tests/basic.nix { changelog-d = finalAttrs.finalPackage; };
};
meta = oldAttrs.meta // {
homepage = "https://codeberg.org/fgaz/changelog-d";
maintainers = [ lib.maintainers.roberth ];
};
};
in
(haskellModifications hsPkg).overrideAttrs mkDerivationOverrides