-
Notifications
You must be signed in to change notification settings - Fork 238
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
[RRFC] npm publish should fail when the files
is misconfig in package.json
#390
Comments
+1 |
IMHO, the similar check should also be applied to the file |
This was discussed last week, and revisited this week. https://github.com/npm/rfcs/blob/latest/meetings/2021-06-23.md#issue-390-rrfc-npm-publish-should-fail-when-the-files-is-misconfig-in-packagejson---aladdin-add Unfortunately, since This is a case where npm cannot reasonably infer the user's intent in a general way. If you want to build a |
this is from npm/feedback#425
Motivation ("The Why")
it's a common error there is something wrong in the
files
in package.json.pkg.files
not updated, e.g. template => templates.currently npm will publish successfully even with no warnings. I think it make sense to throw an error in this kind of cases.
Example
example in the OP npm/feedback#425
How
Current Behaviour
Desired Behaviour
throw an error/warning if found unmatched patterns (might be a breaking change).
References
The text was updated successfully, but these errors were encountered: