holmari / gerritstats

Tool for creating statistics from a Gerrit repository
MIT License
195 stars 54 forks source link

Unable to install on OSX #36

Closed Schrye-zz closed 6 years ago

Schrye-zz commented 6 years ago

Hello,

I am trying to install this on OSX ElCapitan. On running ./gradlew assemble I was prompted to run as admin so I retried using sudo. Am getting the following error

npm ERR! path /workspaces/gerrit/gerritstats/GerritStats/node_modules/npm/node_modules/dezalgo
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall rename
npm ERR! enoent ENOENT: no such file or directory, rename '/workspaces/gerrit/gerritstats/GerritStats/node_modules/npm/node_modules/dezalgo' -> '/workspaces/gerrit/gerritstats/GerritStats/node_modules/npm/node_modules/.dezalgo.DELETE'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/nprabhu/.npm/_logs/2018-01-23T00_30_56_048Z-debug.log
:GerritStats:npmInstall FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':GerritStats:npmInstall'.
> Process 'command 'npm'' finished with non-zero exit value 254

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

I tried installing dezalgo using npm: npm install dezalgo but this does not solve my problem.

Any suggestions would be most helpful.

Schrye-zz commented 6 years ago

Was able to solve this using

npm config set package-lock false
sudo ./gradlew clean
sudo ./gradlew assemble

This is related to https://github.com/npm/npm/issues/17444