通过npm git + ssh安装软件包时出错

时间:2019-06-11 14:54:36

标签: node.js git npm npm-install

我想在我的一个项目中安装一个自制插件作为依赖项。根据互联网,我应该能够从如下所示的私人仓库中安装软件包:

contourf

不幸的是,这导致以下错误

import numpy as np
import matplotlib.pyplot as plt
x = np.linspace(-1, 1, 101)
y = x
x, y = np.meshgrid(x, y)
z = np.exp(-(x**2 + y**2) / 10)       
fig,ax2 = plt.subplots(1)    
ax2.contourf(x,y,z)
plt.show()

在使用公共存储库(例如npm i git+ssh://git@github.com:<myGithubUsername>/<myRepo>.git

)时,我遇到了相同的错误

npm ERR! Command failed: git clone --mirror -q ssh://git@github.com/<username>/<repo>.git C:\Users\me\AppData\Roaming\npm-cache\_cacache\tmp\git-clone-76748c72\.git --config core.longpaths=true npm ERR! /cygdrive/c/Users/me/AppData/Roaming/npm-cache/_cacache/tmp/git-clone-76748c72/C:\Users\<me>\AppData\Roaming\npm-cache\_cacache\tmp\git-clone-76748c72\.git: No such file or directory 尽管有效

如何通过github通过NPM正确安装软件包?

0 个答案:

没有答案
相关问题