Installing with native NPM #75

Closed
opened 2026-02-28 18:47:47 -06:00 by GiteaMirror · 5 comments
Owner

Originally created by @JamiesonRoberts on GitHub (May 3, 2022).

As a heads up, the post-install step fails when a user is using native NPM to install instead of yarn due to the following issue noted in the patch-package project

https://github.com/ds300/patch-package/issues/14

The simplest solution appears to be to change patch-package to ./node_modules/.bin/patch-package in the NPM script

That being said, its impossible to use the project without yarn right now as there are no dependancies in the package.json file. Not everyone uses yarn or wants too.

Originally created by @JamiesonRoberts on GitHub (May 3, 2022). As a heads up, the post-install step fails when a user is using native NPM to install instead of yarn due to the following issue noted in the patch-package project https://github.com/ds300/patch-package/issues/14 The simplest solution appears to be to change `patch-package` to `./node_modules/.bin/patch-package` in the NPM script That being said, its impossible to use the project without yarn right now as there are no dependancies in the package.json file. Not everyone uses yarn or wants too.
Author
Owner

@TomAFrench commented on GitHub (Aug 23, 2022):

Hey Jamieson, to be honest I don't think we're going to be supporting using npm by itself.

Development can only be done in one or the other due to incompatible lock files so there's not much benefit in attempting to support both. We're also using a number of yarn specific features for monorepo management in many of the build scripts so it'll rapidly become impossible to maintain support for both.

I understand this isn't the answer you'd prefer but in much the same way I need to use npm with some repositories where that has been chosen as the package manager while I'd prefer yarn.

@TomAFrench commented on GitHub (Aug 23, 2022): Hey Jamieson, to be honest I don't think we're going to be supporting using npm by itself. Development can only be done in one or the other due to incompatible lock files so there's not much benefit in attempting to support both. We're also using a number of yarn specific features for monorepo management in many of the build scripts so it'll rapidly become impossible to maintain support for both. I understand this isn't the answer you'd prefer but in much the same way I need to use npm with some repositories where that has been chosen as the package manager while I'd prefer yarn.
Author
Owner

@JamiesonRoberts commented on GitHub (Aug 24, 2022):

I get it, as a compromise, would it be possible to update it to make it work with a local yarn install rather than having to have yarn globally installed?

Any time I've ever had both installed globally they massively conflict with each other, not to mention if you use nvm for multiple node versions, you end up having to install yarn for each version of node.

@JamiesonRoberts commented on GitHub (Aug 24, 2022): I get it, as a compromise, would it be possible to update it to make it work with a local yarn install rather than having to have yarn globally installed? Any time I've ever had both installed globally they massively conflict with each other, not to mention if you use nvm for multiple node versions, you end up having to install yarn for each version of node.
Author
Owner

@TomAFrench commented on GitHub (Aug 24, 2022):

We recently migrated to yarn v3 which is always locally installed. Granted my global yarn v1 install may be helping to find that local yarn v3 install but it might work fine for you as well.

@TomAFrench commented on GitHub (Aug 24, 2022): We recently migrated to yarn v3 which is always locally installed. Granted my global yarn v1 install may be helping to find that local yarn v3 install but it might work fine for you as well.
Author
Owner

@JamiesonRoberts commented on GitHub (Aug 24, 2022):

Awesome thank you, forgive my ignorance around yarn, but are there different instructions for installing it and running it? Your current documentation would imply you still need yarn globally installed to run it?

@JamiesonRoberts commented on GitHub (Aug 24, 2022): Awesome thank you, forgive my ignorance around yarn, but are there different instructions for installing it and running it? Your current documentation would imply you still need yarn globally installed to run it?
Author
Owner

@TomAFrench commented on GitHub (Aug 24, 2022):

Based on yarn's docs you still need a global yarn install but the version shouldn't really matter as long as it's recent enough to hand over to the locally installed yarn v3

@TomAFrench commented on GitHub (Aug 24, 2022): Based on [yarn's docs](https://yarnpkg.com/getting-started/migration#step-by-step) you still need a global yarn install but the version shouldn't really matter as long as it's recent enough to hand over to the locally installed yarn v3
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#75