HackYourFuture-CPH / boilerplate-for-fp

Boilerplate for Final projects
4 stars 8 forks source link

force-yarn-install #155

Closed dpfernandes closed 2 years ago

dpfernandes commented 2 years ago

Description

Adding yarn as an engine to package.json and adding a message to npm as an engine so that if the user tries to run npm install it will return with the message "please-use-yarn".

How to test?

Try to run npm install and you should see on the screen something like this

danielfernandes@Daniels-MacBook-Pro boilerplate-for-fp % npm install

npm ERR! code ENOTSUP
npm ERR! notsup Unsupported engine for hyf-final-project-monorepo@: wanted: {"npm":"please-use-yarn","yarn":">= 1.19.1"} (current: {"node":"14.17.4","npm":"6.14.14"})
npm ERR! notsup Not compatible with your version of node/npm: hyf-final-project-monorepo@
npm ERR! notsup Not compatible with your version of node/npm: hyf-final-project-monorepo@
npm ERR! notsup Required: {"npm":"please-use-yarn","yarn":">= 1.19.1"}
npm ERR! notsup Actual:   {"npm":"6.14.14","node":"14.17.4"}

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/danielfernandes/.npm/_logs/2022-04-24T17_37_01_891Z-debug.log
danielfernandes@Daniels-MacBook-Pro boilerplate-for-fp % 

Checklist