I have a project, where the npm install or npm ci fails on Jenkins because this package has its .git folder packed.
npm ERR! path /srv/jenkins/workspace/someProject/node_modules/@cospired/i18n-iso-languages
npm ERR! code EISGIT
npm ERR! git /srv/jenkins/workspace/someProject/node_modules/@cospired/i18n-iso-languages: Appears to be a git repo or submodule.
npm ERR! git /srv/jenkins/workspace/someProject/node_modules/@cospired/i18n-iso-languages
npm ERR! git Refusing to remove it. Update manually,
npm ERR! git or move it out of the way first.
I can reproduce that the .git folder gets installed via npm i https://github.com/cospired/i18n-iso-languages.git (npm 6.4.1, node v10.15.3, macOS 10.14.6).
When I wanted to open a PR I can not reproduce the error with npm pack locally. Maybe you built it with another npm version?
Usually a .npmignore file with a .git entry should prevent it from being packed.
I have the same problem, it's very easy to reproduce. Just try to run npm install a second time with this as a dependency and it happens. I'm also on npm 6.4.1 and node v10.15.3.
Hey everyone,
I have a project, where the
npm install
ornpm ci
fails on Jenkins because this package has its.git
folder packed.I can reproduce that the
.git
folder gets installed vianpm i https://github.com/cospired/i18n-iso-languages.git
(npm 6.4.1, node v10.15.3, macOS 10.14.6).When I wanted to open a PR I can not reproduce the error with
npm pack
locally. Maybe you built it with another npm version?Usually a
.npmignore
file with a.git
entry should prevent it from being packed.Please let me know if you can reproduce it.
I would be happy to help!
Cheers, Jonah