nodePackages.postcss-cli: fix execution of binary
Without this change, executing the postcss binary results in the following error: Error [ERR_MODULE_NOT_FOUND]: Cannot find package 'postcss' Thanks to https://github.com/NixOS/nixpkgs/issues/145618#issuecomment-1051347961 I finally managed to fix this. For some reason `wrapProgram` is still needed though. Fixes https://github.com/NixOS/nixpkgs/issues/145618.
This commit is contained in:
parent
9dc7fafa42
commit
757affafd3
|
@ -343,6 +343,7 @@ let
|
|||
wrapProgram "$out/bin/postcss" \
|
||||
--prefix NODE_PATH : ${self.postcss}/lib/node_modules \
|
||||
--prefix NODE_PATH : ${self.autoprefixer}/lib/node_modules
|
||||
ln -s '${self.postcss}/lib/node_modules/postcss' "$out/lib/node_modules/postcss"
|
||||
'';
|
||||
passthru.tests = {
|
||||
simple-execution = pkgs.callPackage ./package-tests/postcss-cli.nix {
|
||||
|
|
Loading…
Reference in a new issue