Cakephp - 与“thechaw”战斗;在 git 上

发布于 2024-09-10 15:39:37 字数 1102 浏览 3 评论 0原文

我觉得我尝试了一切从 git 克隆 http://thechaw.com/source 但没有成功。我有一个创建 SSH 密钥来访问这个 git,我相信我遵循了指示,但我错过了一些简单的东西。

我遵循了所有说明(http://thechaw.com/wiki/guides/setup) 。有人可以告诉我我出了什么问题吗?

  1. 第一:

    <代码>% cd ~/.ssh && sh-keygen

  2. 将我的密钥添加到他们的“帐户”部分(我假设该密钥遗漏了“ssh-ras”和“me@mydomain”`
  3. 然后:

    % git config --global user.name "<我的 git 用户名>"

    % git config --global user.email <我的 git 电子邮件地址>

  4. 现在我尝试使用克隆

    % sudo git clone [电子邮件受保护]:chaw .git

我总是收到:

Initialized empty Git repository in /var/www/chaw/chaw/.git/
Permission denied (publickey).
fatal: The remote end hung up unexpectedly

我已经尝试了很多小时。我缺少什么?我有一个 github 帐户,我什至将我的 ssh 密钥放在那里(但我相信这不会有任何影响)。

任何帮助将不胜感激。谢谢!

I feel like I tried everything to clone http://thechaw.com/source from git with no success. I have a create SSH keys in order to access this git and I believe I followed the directions but I'm missing something easy.

I followed all the instructions (http://thechaw.com/wiki/guides/setup). Can someone tell me what I'm going wrong?

  1. First:

    % cd ~/.ssh && sh-keygen

  2. Added my key to their "account" section (I assume the key leaves off the "ssh-ras" and the "me@mydomain"`
  3. Then:

    % git config --global user.name "<My git Username>"

    % git config --global user.email <My git Email address>

  4. Now I try to clone using

    % sudo git clone [email protected]:chaw.git

I always receive:

Initialized empty Git repository in /var/www/chaw/chaw/.git/
Permission denied (publickey).
fatal: The remote end hung up unexpectedly

I've been trying for many hours. What am I missing? I have a github account and I even put my ssh key in there (but I believe that shouldn't have any effect).

Any help would be appreciated. Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

尬尬 2024-09-17 15:39:37

我相信您将 ssh 密钥和 Git 配置添加到非 root 用户,但随后使用“sudo”进行克隆,从而使 Git 找不到您的用户密钥(因为它以 root 身份运行)。

I believe you added the ssh key and Git configuration to your non-root user, but then used "sudo" to do the clone thereby making Git not find your user's keys (since it's running as root).

鹿! 2024-09-17 15:39:37

花了相当长的时间,这就是我最终做到的。我无法让它在 rsa 上运行,所以我尝试了 dsa,然后它就工作了:

ssh-keygen -t dsa -C "myemailIUsedAtthechaw.com"


cat ~/.ssh/id_dsa.pub | xclip -sel clip

然后进入我在 thechaw 的帐户并将其粘贴到 git 密钥字段中。

然后我

git clone [email protected]:chaw.git

就检查出来了。这真是一种解脱。 :)

spent quite some time and this is how i finally did it. i couldnt get it running on rsa so i tried dsa and then it just worked:

ssh-keygen -t dsa -C "myemailIUsedAtthechaw.com"


cat ~/.ssh/id_dsa.pub | xclip -sel clip

then just went into my account at thechaw and pasted it into the git key field.

then i

git clone [email protected]:chaw.git

n it checked out. wat a relief. :)

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文