Xcode 不会在 SVN 中选取新的类文件 [英] Xcode does not pick up new class files in SVN

查看:27
本文介绍了Xcode 不会在 SVN 中选取新的类文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个 SVN 存储库,我从中更新了我的本地代码,此更新包括新的类文件.当我开始构建时,由于之前在 Xcode 中的文件中的代码已更新并引用了新文件,因此出现链接器错误.此文件已添加到我在 Finder 中的目录中(即我的本地文件系统是最新的),但这些新文件尚未添加到我的 xcode 中.

I have an SVN repository that I have updated my local code from, and this update included new class files. When I went to build, there was a linker error due to the fact that code in my files that were previously in Xcode had been updated and referenced a new file. this file has been added to my directory in Finder (i.e. my local filesystem is up to date) but these new files have not been added to my xcode.

我的问题是:Xcode 如何找到新文件?或者哪个元数据文件存储显示在 Xcode 右侧窗格中的文件?(所以我可以检查这是否更新)

My question is: how do new files become found by Xcode?? or which metadata file stores the files that show up in the right hand pane in Xcode? (so I can check if this is updated or not)

推荐答案

在 Finder 中右键单击 MyProject.xcodeproj 并选择 Show Package Contents.这将显示 XCode 用于控制项目结构的三个文件.如果您熟悉这些,这就像 Visual Studio 中的解决方案和项目文件.

Within Finder right click on MyProject.xcodeproj and select Show Package Contents. This will display the three files XCode uses to control the project structure. This is like the solution and project files from Visual Studio if you are familiar with those.

在包内容中是每个用户的文件,.pbxuser 和其他文件,具体取决于 Core Data 的使用情况.您需要的密钥文件是 project.pbxproj.我们使用 XCode 将我们的 SVN 检入到 SVN 中,当它更新并且您更新项目时,您将收到一条警告,询问您是要保留现有磁盘还是读取磁盘.读取磁盘以获取 SVN 已下拉到您的开发机器的新添加文件.

Within the package contents are files for each user, <username>.pbxuser and others depending on things like Core Data usage. The key file you need is project.pbxproj. We check ours into SVN with XCode and when it gets updated and you update the project you'll get a warning asking you if you want to keep your existing or read off disk. Read of the disk to pick up the newly added files that SVN has pulled down to your dev machine.

如果您对项目进行了自己的更改,包括添加任何新文件、组等,请务必小心确保解决冲突.比较工具对于选择正确的更改很有用,但我发现我必须这样做将合并的 project.pbxproj 文件保存在别处,然后手动添加回 MyProject.xcodeproj 包.

Be very careful to ensure that you resolve conflicts if you've made your own changes to the project including adding any new files, groups etc. The compare tool is useful to select the right changes but I've found I had to save the merged project.pbxproj file elsewhere and then manually add back in to the MyProject.xcodeproj package.

从 Windows 机器管理项目的重复副本会更容易,因为我还没有找到适用于 Tortoise 的 SVN 的 OSX 客户端.

It can be easier to manage a duplicate copy of the project from a Windows machine as I;ve yet to find an OSX client for SVN that gets anywhere near Tortoise.

这篇关于Xcode 不会在 SVN 中选取新的类文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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