【问题标题】:Yarn not install git private repositories纱线不安装 git 私有存储库
【发布时间】:2017-10-24 05:08:45
【问题描述】:

我正在使用 yarn,但它对私有 git 存储库给出了以下错误。 npm 成功安装了这个 repo。

yarn install v1.2.1
info No lockfile found.
[1/4] ????  Resolving packages...
error Command failed.
Exit code: 128
Command: git
Arguments: ls-remote --tags --heads ssh://git@github.com/test/testconfigs.git
Directory: /Users/admin/Projects/Demo/myProject
Output:
Permission denied (publickey).
fatal: Could not read from remote repository.

【问题讨论】:

标签: git yarnpkg


【解决方案1】:

这对我有用:

将 GitHub 密钥添加到授权主机列表中:

ssh-keyscan -t rsa github.com >> ~/.ssh/known_hosts

原答案:

Git error: "Host Key Verification Failed" when connecting to remote repository

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2018-08-02
    • 1970-01-01
    • 2019-05-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-11-24
    • 1970-01-01
    相关资源
    最近更新 更多