-
Notifications
You must be signed in to change notification settings - Fork 2.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[yarn run] Arguments are passed to pre and post scripts #1595
Comments
Created #1596 to fix this, pending approval. |
Thank you for your quick response! |
Apologies for digging the dead but I am stuck around this issue.
I want to check for the version of installing package at preinstall and verify that it's version is above "1.0.0" (or other policy) else don't let them install. I would expect, pre and post hooks/scripts to have same context or access to same context as original script. If I was doing @kittens Do you know if I can still achieve this? |
same question as @Vivekbhusal. My use case is with React Native. When you uninstall a package you need to run an extra command
🙁 Would be great to be able get the name of the package e.g. from the |
@gianpaj @Vivekbhusal looks like they had support for it and then removed it as a bug. |
Do you want to request a feature or report a bug?
bug
What is the current behavior?
When I run a script with arguments by
yarn run
, the arguments are passed to not only the scripts but also its pre and post scripts.If the current behavior is a bug, please provide the steps to reproduce.
will output:
What is the expected behavior?
The arguments are not passed to pre and post scripts.
npm passes the arguments only to the main script.
Please mention your node.js, yarn and operating system version.
The text was updated successfully, but these errors were encountered: