coral-xyz / anchor

⚓ Solana Sealevel Framework
https://anchor-lang.com
Apache License 2.0
3.71k stars 1.36k forks source link

yarn install fails with no yarn installed #3298

Open nickfrosty opened 1 month ago

nickfrosty commented 1 month ago

when running anchor init to scaffold a new anchor workspace the command fails on the yarn install step with the following error:

Error: yarn install failed: No such file or directory (os error 2)

to note, yarn is not installed on this system since it was just freshly setup with all the usual local solana tooling. at a quick glance of the anchor code, I see it attempts to fallback to npm for installing the node modules, but for some reason it is not for me

system details:

nickfrosty commented 1 month ago

looks like this might be related to this issue: https://github.com/coral-xyz/anchor/issues/3281

acheroncrypto commented 1 month ago

This should be fixed when we make npm the default (see https://github.com/coral-xyz/anchor/issues/2881).

nickfrosty commented 1 month ago

amazing!

arihantbansal commented 3 weeks ago

@nickfrosty You can now pass in the package manager you want to use, see #3328