Skip to content
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

Safely stop tests and build running on npm install #242

Merged
merged 2 commits into from
Dec 15, 2016

Conversation

pimterry
Copy link
Contributor

This halves the number of tests we run, working towards #241.

This script makes NPM prepublish never run the tests or CS build. Instead, those are run in NPM@4's new prepublishOnly step, which only happens on an actual publish, not on simple npm install's.

To make this safe, we have to catch any users that aren't using NPM@4, but are trying to publish - require-NPM4-to-publish does that, and gets triggered by any actual publishes when they trigger prepublish.

Tested locally with NPM 4.0.3 and NPM 3.10.10.

Copy link
Contributor

@emirotin emirotin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job!
NIT: I'd make npm4 lowercase

@pimterry
Copy link
Contributor Author

Sure, done.

@pimterry pimterry merged commit 7a44833 into sdk-browser Dec 15, 2016
@pimterry pimterry deleted the 241-fix-prepublish branch December 15, 2016 16:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants