-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
feat: enforce pnpm 7.5.0 #1125
feat: enforce pnpm 7.5.0 #1125
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
✅ Deploy Preview for docs-novu canceled.
|
Reason for failing NX build command: nrwl/nx#10111 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great, a small comment on the setup:project command wdyt on that one?
package.json
Outdated
"scripts": { | ||
"bootstrap": "npm run setup:dev", | ||
"start": "npm run jarvis", | ||
"preinstall": "npx only-allow pnpm", | ||
"prepare": "husky install", | ||
"publish": "lerna publish from-package", | ||
"setup:project": "npx pnpm@7.5.0 i && node scripts/setup-env-files.js && npx pnpm build", | ||
"setup:project": "pnpm i && node scripts/setup-env-files.js && pnpm build", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"setup:project": "pnpm i && node scripts/setup-env-files.js && pnpm build", | |
"setup:project": "npx pnpm i && node scripts/setup-env-files.js && npm run build", |
Wanted to have the initial setup of the project work without pnpm installed on your machine, and you would need it only if you want to add some dependencies. Wdyt, of only leaving the npx here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah we can do that, true 🙂 But we still need to lock the version number then because it will otherwise install the latest pnpm and we can leave pnpm in the end because it is installed after running the pnpm i
- I commited it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good point about the lock part. Agree with this.
@@ -111,7 +112,7 @@ | |||
"listr": "^0.14.3", | |||
"meow": "^10.1.1", | |||
"mississippi": "^4.0.0", | |||
"pnpm": "^6.34.0", | |||
"pnpm": "7.5.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is great!
@@ -1,13 +1,14 @@ | |||
{ | |||
"name": "novuhq", | |||
"private": true, | |||
"packageManager": "pnpm@7.5.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh nice didn't knew this prop existed
Oh Looks like vercel is failing :|
We are looking right now to switch to netlify and they allow easily override the install script on their dashboard. |
@andrewgolovanov this one is another reason we want to make the move to netlify for all our projects. |
@scopsy maybe you can use this? https://vercel.com/changelog/corepack-experimental-is-now-available - thats why I added that packageManager field |
It worked! |
@scopsy is attempting to deploy a commit to the Novu Team on Vercel. A member of the Team first needs to authorize it. |
What kind of change does this PR introduce? (Bug fix, feature, docs update, ...)
This fixes some issues with pnpm that I had while creating PRs for Novu:
1. Newer versions of pnpm will break the CI and seem to install unneeded packages.
Reference: refactor: use date-fns instead of moment #1122
Solution: Enforce pnpm version of 7.5.0
2. When running
npm run setup:project
for the first time everything works as inteded. But if you run that command again it would downgrade your pnpm-lock.yaml to lockfileVersion 5.3Reference inside feat: enable custom theme to be provided to iframe embed #1048:
That was an issue because of the repos
package.json
havingpnpm: 6.34.0
as devDependency and npx falling back to the local cached version instead of using the version number provided in the cli command:Solution: Increase the devDependency version of pnpm to 7.5.0