从git repository管理版本npm

时间:2017-07-19 09:51:22

标签: git npm

我可以使用>等符号来管理依赖项。

阅读文档,似乎有可能https://docs.npmjs.com/files/package.json#git-urls-as-dependencies

例如,这个正在运作

"dependencies": {
    "module": "git+ssh://git@github.com:company/module.git#v1.0.6"
}

这个也是

"dependencies": {
    "module": "git+ssh://git@github.com:company/module.git#1.0.6"
}

但是这种语法失败了

"dependencies": {
    "module": "git+ssh://git@github.com:company/module.git^1.0.6"
}

我有以下错误

npm ERR! git clone --template=/Users/ajouve/.npm/_git-remotes/_templates --mirror ssh://git@github.com/com:company/module.git%5E1.0.6.git /Users/ajouve/.npm/_git-remotes/git-ssh-git-github-com-com:company-module-git-5E1-0-6-git-0d36a656:    is not a valid repository name

我的npm版本是3.10.10

0 个答案:

没有答案
相关问题