对Mac的“捆绑"版本进行版本控制的最佳方法是:档案 [英] Best approaches to versioning Mac "bundle" files

查看:131
本文介绍了对Mac的“捆绑"版本进行版本控制的最佳方法是:档案的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

因此,您知道许多Mac应用程序都使用捆绑包":对于您的应用程序来说,它看起来像是一个文件,但实际上是一个文件夹,其中包含许多文件.

So you know a lot of Mac apps use "bundles": It looks like a single file to your application, but it's actually a folder with many files inside.

要让版本控制系统处理此问题,它需要:

For a version control system to handle this, it needs to:

  • 检出目录中的所有文件,以便应用程序可以根据需要修改它们
  • 在办理登机手续时,
    • 提交已修改的文件
    • 添加应用程序创建的新文件
    • 将其标记为不再存在的已删除文件(因为应用删除了这些文件)
    • 将其作为一项原子变化进行管理
    • check out all the files in a directory, so the app can modify them as necessary
    • at checkin,
      • commit files which have been modified
      • add new files which the application has created
      • mark as deleted files which are no longer there (since the app deleted them)
      • manage this as one atomic change

      您对使用现有版本控制系统解决此问题的最佳方法有何想法?是否有任何版本控制系统更擅长于此领域?

      Any ideas on the best way to handle this with existing version control systems? Are any of the versioning systems more adept in this area?

      推荐答案

      对于像git和mercurial这样的分布式SCM系统,就像Matthew所提到的那样,应该不是问题.

      For distributed SCM systems like git and mercurial shouldn't be a problem as Matthew mentioned.

      如果您需要使用Subversion或CVS之类的集中式SCM,则可以将捆绑软件压缩(存档),然后再将其检入源代码管理.这可能会很痛苦,并且需要额外的步骤.在Tapestry Central上有一篇很好的博客文章:

      If you need to use a centralized SCM like Subversion or CVS, then you can zip up (archive) your bundles before checking them into source control. This can be painful and takes an extra step. There is a good blog post about this at Tapestry Central:

      Mac OS X捆绑软件与Subversion

      本文演示了一个红宝石脚本,该脚本为您管理归档.

      This article demonstrates a ruby script that manages the archiving for you.

      这篇关于对Mac的“捆绑"版本进行版本控制的最佳方法是:档案的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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