简体   繁体   English

无法推送git readynas

[英]can't push git readynas

I am writing an app using xcode 4. I have no experience with git, or any form of source control other than copy/paste a new folder! 我正在使用xcode 4编写应用程序。除了复制/粘贴新文件夹之外,我没有git或任何形式的源代码控制方面的经验!

I have setup git on my readyNAS duo using this Guide 我已使用本指南在readyNAS二重奏上设置了git

I can then add the repository in xcode using: 然后,我可以使用以下代码在xcode中添加存储库:

ssh://root@192.168.1.10/opt/git/Developer

Developer being the repository. 开发人员是资源库。

Xcode then gives me the option to clone, which it can do and it creates an empty repository in the filesystem on the client(MacBook Pro)(I expect it to be empty as I haven't pushed anything to it)! Xcode然后为我提供了克隆的选项,它可以执行此操作,并且它会在客户端(MacBook Pro)的文件系统中创建一个空的存储库(我希望它是空的,因为我还没有对它进行任何操作)!

Any program started and saved in the developer folder can commit locally, however when I wish to push over the network I get this error: 启动并保存在开发人员文件夹中的任何程序都可以在本地提交,但是当我希望通过网络推送时,出现此错误:

fatal: 'Developer' does not appear to be a git repository fatal: The remote end hung up unexpectedly 致命:“开发人员”似乎不是git存储库致命:远程端意外挂断

As a newbie I really don't have any idea about the source of the problem, I have tried this from two client Mac's running snow leopard to my ReadyNAS Duo running 4.1.7. 作为一个新手,我真的不知道问题的根源,我已经尝试了从两个客户端Mac的雪豹到运行4.1.7的ReadyNAS Duo。

What do I need to do to address this problem? 我需要怎么做才能解决这个问题?

Try doing this from Terminal: 尝试从终端执行此操作:

Go to the repository location ( wherever XCode cloned your repo) 转到存储库位置(无论XCode将存储库克隆到何处)

Run

git remote add Developer ssh://root@192.168.1.10/opt/git/Developer

Now try doing the push. 现在尝试进行推送。 I am not familiar with how XCode's git integration works, but the error suggests that it is trying to use a remote named Developer, which is not found. 我不熟悉XCode的git集成的工作原理,但是该错误表明它正在尝试使用未找到的名为Developer的远程。

Usually, it should try doing it on origin, which is the remote that is automatically setup when you clone. 通常,它应尝试在原点进行操作,该原点是克隆时自动设置的远程。 See if you can change the remote that it is trying to pust to. 看看是否可以更改要尝试输入的遥控器。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM