Search code examples
npmgitlabyarnpkg.npmrc

How to install private git library to npm project?


In a project which I work with there is private project library which is available for me directly - https://gitlab.some-project/some-utils In package.json it is requested like

  "dependencies": {
    "@some-project/some-utils": "0.1.42",
    ...
   }

This project wasn't uploaded to npm. I created .npmrc file and put there:

@8some-project:registry=https://gitlab.some-project.com/some-utils

But when I try to "run yarn @some-project/some-utils" I get:

error Received malformed response from registry for "@some-project/some-utils". The registry may be down.

What I am doing wrongly? How to install this library to another project?


Solution

  • I just raised npm version and it works now