SVN 外部标记流程

发布于 2024-12-08 11:17:53 字数 464 浏览 0 评论 0原文

我只有一个存储库。

假设我有跨项目共享的 LibraryX。

假设 ApplicationA(以及其他)使用 LibraryX 并将其作为外部引用。

在开发 ApplicationA 时,我也可能对 LibraryX 进行修改。

假设对 ApplicationA 和 LibraryX 都进行了更改,现在我正在发布。

如果您同意/不同意以下流程,请告诉我,和/或告诉我您将采取哪些措施来改进它:

  • 的标签
  • 创建 LibraryX分支 ApplicationA
  • ,更改分支 ApplicationA 上的外部以指向标记的 LibraryX,也许还指向特定的修订(以防将来有人意外提交该标签)
  • 创建分支 ApplicationA 的标签
  • 删除分支 ApplicationA

听起来合理吗?有更好的想法吗?想法?

I have one single repository.

Suppose I have LibraryX which I share across projects.

Suppose ApplicationA (among others) uses LibraryX and references it as an external.

While developing ApplicationA, I am also possibly making modifications to LibraryX.

Suppose changes have been made to both ApplicationA and to LibraryX, and now I am doing a release.

Please tell me if you agree/disagree with the following process, and/or tell me what you would do to improve it:

  • create a tag of LibraryX
  • branch ApplicationA
  • change externals on the branched ApplicationA to point to the tagged LibraryX and perhaps to the specific revision (in case someone in the future commits to the tag accidentally)
  • create a tag of the branched ApplicationA
  • delete the branched ApplicationA

Sound reasonable? Got better ideas? Thoughts?

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

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

发布评论

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

评论(2

落在眉间の轻吻 2024-12-15 11:17:53

我执行以下操作:

  • 我总是在特定修订版中引用该库。如果库发生变化并且我希望在我的应用程序中进行更改,那么我会更新外部定义。
  • 在发布时,我创建应用程序的标签。我不需要采取额外的步骤,因为引用了该库的特定修订版。

一些补充意见:

  • 有时我不会引用特定版本的库(因为我太懒了),但我知道这些修订将来将无法使用。如果您意识到这一点,您就可以做出这个决定。但是,在创建标签之前,我总是冻结库引用。
  • 有时我会创建一个分支而不是标签,这样我就可以修复一些错误,同时继续开发下一个版本。最终我为这个分支创建了一个标签并删除该分支。 (也许我创建了多个标签,但分支总是在最后被删除。)
  • 我删除分支是因为我仅将分支用作短期实体:功能分支或发布分支来稳定发布。我不需要保留分支,因为标签是我感兴趣的版本。
  • 如果我需要修复标签中的错误,那么我首先创建一个分支。修复错误并创建新标签(并删除分支)。
  • 如果需要在库中修复错误(尽管有点复杂),则同样适用:在分支中,您可以更新到最新的库(如果可能),或者创建引用版本的分支 图书馆的。然后,您将外部更改为指向此分支,修复库中的错误,将外部定义冻结到库分支的最新版本,并为应用程序创建一个标签。我通常不会费心为库创建标签,但这也是可能的。不过,我确实删除了库分支:如果再次需要它,您可以根据已删除库分支的最后修订版创建一个新分支。

I do the following:

  • I always reference the library in a specific revision. If the library changes and I want the change in my application then I update the externals definition.
  • On release I create a tag of the application. I do not need to take extra steps, since a specific revision of the library is referenced.

Some additional comments:

  • Sometimes I do not references a specific version of the library (because I am too lazy), but I am aware that these revisions will not be usable in the future. This is a decision you can make if you are aware of it. However, before I create a tag, I always freeze the library reference.
  • Sometimes I create a branch instead of a tag, so that I can fix some bugs and at the same time continue to work on the next release. Eventually I create a tag for this branch and delete the branch. (Maybe I create more then one tag, but the branch always gets deleted at the end.)
  • I delete branches because I use branches only as short-lived entities: feature branches or release branches to stabilize a release. There is no need for me to keep the branch around since tags are the versions I am interested in.
  • If I need to fix a bug in a tag then I create a branch first. Fix the bug and create a new tag (and delete the branch).
  • The same applies if the bug needs to be fixed in the library (though a bit more complicated): In the branch you either update to the latest library (if possible) or you create a branch of the referenced revision of the library. Then you change the external to point to this branch, fix the bug in the library, freeze the externals definition to the latest revision of the library branch and create a tag for the application . I usually do not bother to create a tag for the library, but it would also be possible. I do however delete the library branch: If it is ever needed again you can create a new branch based on the last revision of the deleted library branch.
み青杉依旧 2024-12-15 11:17:53
  1. 外部标记是浪费时间
  2. ApplicationA 的分支 + 编辑(修复 LibraryX 的版本) svn: 分支中的外部 + 提交 + 将分支中的最后一个修订标记为“产品标签”
  1. Tag for external is waste of time
  2. Branch for ApplicationA + edit (fix rev. of LibraryX) svn:external in branch + commit + tag last revision in branch as "product tag"
~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文