Mike K.
Mike K.

Reputation: 608

Installing private NPM module over GIT, and having it update?

I looked at this answer, which shows you how to install npm modules from private git (sub)folders. This works correctly for me when I do: npm install git+ssh://[email protected]:myaccount/myprivate.git, my main application can then call the code in the private module.

But when someone updates the module in the github.com:myaccount/myprivate.git location, I want my main application to receive these updated changes.

What I want to do is:

As a work-around I have to:

Upvotes: 1

Views: 133

Answers (1)

roboli
roboli

Reputation: 1478

You could use git commit hashes to keep track of your changes:

npm i --save git+ssh://[email protected]:myaccount/myprivate.git#b0f2009

or tags

npm i --save git+ssh://[email protected]:myaccount/myprivate.git#v0.0.2

Upvotes: 1

Related Questions