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

ci: run install scripts for root project #2316

Merged
merged 1 commit into from
Dec 11, 2020
Merged

Conversation

isaacs
Copy link
Contributor

@isaacs isaacs commented Dec 9, 2020

npm ci should run all the same preinstall/install/postinstall/prepare
scripts for the root project just like npm install.

Fixes: #1905

References

@isaacs isaacs requested a review from a team as a code owner December 9, 2020 22:18
'preinstall',
'install',
'postinstall',
'prepublish', // XXX should we remove this finally??
Copy link
Contributor

Choose a reason for hiding this comment

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

Just wondering, I thought prepublish was deprecated?

Copy link
Contributor

Choose a reason for hiding this comment

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

please don't remove it yet :-) imo the churn isn't worth it. it'd be better to remove prepublishOnly and make prepublish, only running on prepublish, the actual behavior.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think since we already shipped v7, we have this on the agenda for npm v8. It's a breaking change if we remove it, and at least an annoying change (if not actually breaking) if we deprecate it with a warning.

  • remove (or deprecate with a warning) prepublish on install/ci
  • remove (or deprecate with a warning) prepublishOnly

Copy link
Contributor

Choose a reason for hiding this comment

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

Given that’s the plan, I’d prefer the former :-D (which, iirc, was the original planned end state)

@ruyadorno ruyadorno added Release 7.x work is associated with a specific npm 7 release release: next These items should be addressed in the next release labels Dec 11, 2020
`npm ci` should run all the same preinstall/install/postinstall/prepare
scripts for the root project just like `npm install`.

Fixes: #1905

PR-URL: #2316
Credit: @isaacs
Close: #2316
Reviewed-by: @ruyadorno
@isaacs isaacs changed the base branch from latest to release/v7.1.2 December 11, 2020 19:31
@isaacs isaacs merged commit d825e90 into release/v7.1.2 Dec 11, 2020
@isaacs isaacs mentioned this pull request Dec 11, 2020
@nlf nlf deleted the isaacs/ci-scripts branch March 28, 2022 16:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
release: next These items should be addressed in the next release Release 7.x work is associated with a specific npm 7 release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] npm ci doesn't run postinstall script
5 participants