Support PNPM and Others
See original GitHub issueNote: If your feature-request is regarding the AWS Amplify Console service, please log it in the official AWS Amplify Console forum
Is your feature request related to a problem? Please describe.
I suppose you could consider this related to a problem; at present the Amplify CLI is forcing either npm
or yarn
upon the userbase. Locking users into a vendor is never a good idea. I work in a pnpm
shop, and not being able to use that for install during push
is not only putting us as a speed advantage, but it’s forcing us to use a codepath that we didn’t choose.
Describe the solution you’d like
I’d like first-class support for modifying the install command that’s used, or being able to skip the install step altogether, allowing the app’s amplify:{appName}
script to prepare the directory for push. e.g. copying/moving node_modules into the target directory, or running our installer of choice.
Describe alternatives you’ve considered
There aren’t any. Woo!
Additional context
n/a
Issue Analytics
- State:
- Created 3 years ago
- Comments:8 (1 by maintainers)
Oh hey @mikhael28 fancy seeing you here. 😆
First class support would be great, but (commenting here so it can help others if applicable) a workaround that seems to be fairly effective (it solved our deploy issues) is to edit the
amplify.yml
build file to usenpx pnpm install
for preBuild andnpx pnpm build
for build, instead of their yarn or npm counterparts.I’m going to say +1 to asking for first class support for
pnpm
. Meaning, in theBuild Settings
of the Amplify Console, support havingpnpm install
instead of npm or yarn. Frankly, this shouldn’t take too much work - whatever your base image is that runs all of these builds, just install pnpm as one of the initial dependencies. My open-source project just moved topnpm
(loving it, saving space/data from redownloading node_modules) and we are trying to build our app to keep our deployment pipeline going. We also changed to Vite at the same time, so that could be inviting some trouble as well.Either way, we are going to be looking at migrating to another system ASAP for our CI pipeline - trying to use
npm
oryarn
install in the Build settings successfully generates a build… but the hilarious thing is that the build is actually broken, even though Amplify puts it through. That’s a lack of testing on our part, but still - hilarious.