We are using GitLab for our private project. There are some forked libraries from github, that we want to install as npm module. Installing that module directly from npm is
You have the following methods for connecting to a private gitlab repository
With SSH
git+ssh://git@git.mydomain.com:Username/Repository#{branch|tag}
git+ssh://git@git.mydomain.com/Username/Repository#{branch|tag}
With HTTPS
git+https://git@git.mydomain.com/Username/Repository#{branch|tag}
With HTTPS and deploy token
git+https://<token-name>:<token>@gitlab.com/Username/Repository#{branch|tag}
None of the other answers worked for me for a private gitlab.com repo...
This works however:
npm i -S git+ssh://git@gitlab.com:<org>/<project>.git
Its just the git ssh clone url from the project page's "clone" input field with git+ssh://
added to the front of it.
As far as I can tell where you're going wrong is the git://
protocol. GitLab only supports HTTP(s) and SSH for clones. So you must use one of those methods instead of the git protocol.