Xcode 7创建了新的分支,提交失败 [英] Xcode 7 created new branch, commit fails

查看:655
本文介绍了Xcode 7创建了新的分支,提交失败的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

最近升级到Xcode 7与进展中的应用程序。应用程序运行良好,但是当我去提交Xcode 7中的第一次更改时,出现了以下错误:
$ b

工作副本应用程序名称未能提交
error:invalid object 100644 07ce6672fd469d5c7545e48b910cb3ff4508e9ca for'App Name / App Name-Prefix.pch'
error:invalid object 100644 07ce6672fd469d5c7545e48b910cb3ff4508e9ca for'App Name / App Name-Prefix.pch'
错误:构建树错误



然后我注意到我现在在Xcode的源代码控制下有一个额外的分支......一个说Project Name - master 而只有项目名称(没有主人)。以前,自从我自己工作以来,我只在一个主分支上工作。有谁知道为什么升级到XCode 7后发生这种情况?我已经使用现有项目升级了Xcode版本,但从未发生过这种情况。更重要的是,我该如何解决这个问题?

谢谢!

解决方案

在尝试从其他线程获得多个解决方案但没有成功之后,我可以用一个非常简单的解决方案解决这个问题......从本地删除xcode项目并克隆最近的git存储库,然后在XCode中再次打开该项目。我将未保存的更改文件拖到桌面上,然后在克隆之后将其替换,并且一切都恢复良好。这种解决方案可能不适用于所有人,具体取决于情况,但对我来说,它已经足够好了。


Recently upgraded to Xcode 7 with an in progress app. Got app running fine but when I went to commit first changes in Xcode 7, I got the below error:

The working copy "App Name" failed to commit files. error: invalid object 100644 07ce6672fd469d5c7545e48b910cb3ff4508e9ca for 'App Name/App Name-Prefix.pch' error: invalid object 100644 07ce6672fd469d5c7545e48b910cb3ff4508e9ca for 'App Name/App Name-Prefix.pch' error: Error building trees

I then noticed that I now have an additional branch under Source Control in Xcode...one that says "Project Name - master" and one with just the Project name (no master). Previously, I only worked on a master branch since I'm working by myself. Does anyone know why this happened after upgrading to XCode 7? I've upgraded Xcode versions before with existing projects and never had this happen. More importantly, how do I resolve this?

Thanks!

解决方案

After trying multiple solutions to this from other threads with no success, I was able to solve this with a very simple solution...deleted the xcode project locally and cloned the most recent git repository, then opened the project again in XCode. I dragged my unsaved changed files to the desktop first and then replaced them after cloning and all was well again. This solution may not work for everyone depending on the scenario, but it worked well enough for me.

这篇关于Xcode 7创建了新的分支,提交失败的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆