patch-ppd-files: use meta
and passthru
directly
When I authored the nix file in335a9083b0
, `makeSetupHook` didn't know about `passthru` or `meta`. So I foisted these attributes on the derivation with `.overrideAttrs`. Commitsba895a7da8
and48034046bf
enabled `makeSetupHook` to receive these attributes directly. It seems advisable to use that instead of `.overrideAttrs`.
This commit is contained in:
parent
db24d86dd8
commit
fcbf9c6415
|
@ -4,22 +4,15 @@
|
||||||
, callPackage
|
, callPackage
|
||||||
}:
|
}:
|
||||||
|
|
||||||
let
|
makeSetupHook {
|
||||||
patchPpdFilesHook = makeSetupHook
|
name = "patch-ppd-files";
|
||||||
{
|
substitutions = {
|
||||||
name = "patch-ppd-files";
|
which = lib.getBin which;
|
||||||
substitutions.which = lib.attrsets.getBin which;
|
awkscript = ./patch-ppd-lines.awk;
|
||||||
substitutions.awkscript = ./patch-ppd-lines.awk;
|
};
|
||||||
}
|
passthru.tests.test = callPackage ./test.nix {};
|
||||||
./patch-ppd-hook.sh;
|
meta = {
|
||||||
in
|
description = "setup hook to patch executable paths in ppd files";
|
||||||
|
maintainers = [ lib.maintainers.yarny ];
|
||||||
patchPpdFilesHook.overrideAttrs (
|
};
|
||||||
lib.trivial.flip
|
} ./patch-ppd-hook.sh
|
||||||
lib.attrsets.recursiveUpdate
|
|
||||||
{
|
|
||||||
passthru.tests.test = callPackage ./test.nix {};
|
|
||||||
meta.description = "setup hook to patch executable paths in ppd files";
|
|
||||||
meta.maintainers = [ lib.maintainers.yarny ];
|
|
||||||
}
|
|
||||||
)
|
|
||||||
|
|
Loading…
Reference in a new issue