0

I made a custom Yeoman generator using yeoman-generator v 5.8.0, and everything seems to be working fine except that I get an error in the console:

Error detecting the package manager. Falling back to npm.

Which in the end is also fine, it still works, but I'd like it to not report an error.

The only way I can find to specify the package manager to use is either calling one of the specific package manager install functions explicitly, i.e.

this.npmInstall()

or by calling the general installDependencies function with options, i.e.

this.installDependencies({
  npm: true,
  yarn: false,
  bower: false
})

However, since version 5.0.0 all of the install functions are deprecated.

https://yeoman.github.io/generator/actions_install.html

https://github.com/yeoman/generator/releases/tag/v5.0.0

So how do I specify the package manager to use so I won't get that error message?

Dylan Cristy
  • 916
  • 11
  • 29

0 Answers0