criticalmanufacturing / cli

Critical Manufacturing Projects Command Line Tool
https://criticalmanufacturing.github.io/cli/
BSD 3-Clause "New" or "Revised" License
12 stars 28 forks source link

CLI is incompatible with Volta #194

Open pedromsfernandes opened 2 years ago

pedromsfernandes commented 2 years ago

Volta is a tool manager which installs global packages in a different directory than the one returned by npm root --global, which is the one used by the is-installed-globally library. Thus, when trying to run the cli, it does not know that it is installed globally and fails.

For reference, in my machine npm root --global returns: C:\Users\pmfernandes\AppData\Local\Volta\tools\image\node\12.22.12\node_modules

While the global packages are actually stored in: C:\Users\pmfernandes\AppData\Local\Volta\tools\image\packages

Relevant code