关于多个操作系统的SVN目录结构的问题

发布于 2024-11-09 06:18:12 字数 979 浏览 5 评论 0原文

我正在考虑从 Mercurial 迁移到 SVN,因为它似乎更易于维护,而且拥有 SVN 客户端的人比可用的 Mercurial 客户端要多。但是我有一个关于文件结构的问题 -

我知道典型的正确 SVN 结构是:

/trunk
..../当前版本文件在这里

/branch
..../错误修复
..../新功能
..../branch3
..../branchN

/标签
..../版本 1.0
..../版本 2.0
..../version nn

我的问题是这个因素如何影响多个操作系统?我的软件目前为每个操作系统的 GUI/CLI 版本的软件都有单独的 Mercurial 存储库,因为您不能只在 Mercurial 中签出目录。不过,我知道你可以在 SVN 中。结构是否类似于:

/Windows(或 Linux,或其他)

/trunk
..../CLI
...../当前版本文件在这里
..../GUI
...../当前版本文件在这里

/branch
..../CLI
...../错误修复
...../新功能
...../branch3
...../分支N
..../GUI
...../错误修复
...../新功能
...../branch3
...../branchN

/标签
..../CLI
...../版本1.0
...../版本2.0
...../版本nn
..../GUI
...../版本1.0
...../版本2.0
...../version nn

或者我让这太复杂了?您是否建议将 GUI 版本存储在单独的存储库中?另外,预编译的可执行文件存储在哪些典型目录中?

我知道这些问题可能看起来很新手,但事实是我对 SVN 完全陌生。感谢您的帮助!

I'm thinking of moving to SVN from mercurial because it seems simpler to maintain and more people have an SVN client than a mercurial client available. However I have a question regarding file structure -

I understand that the typical proper SVN structure goes:

/trunk
..../current version files here

/branch
..../bugfix
..../newfeature
..../branch3
..../branchN

/tag
..../version 1.0
..../version 2.0
..../version n.n

My question is how does this factor into multiple OSes? My software currently has separate mercurial repositories for the GUI/CLI versions of my software for each OS since you can't only checkout a directory in mercurial. However, I understand you can in SVN. Would the structure look like:

/Windows (or Linux, or whatever)

/trunk
..../CLI
...../current version files here
..../GUI
...../current version files here

/branch
..../CLI
...../bugfix
...../newfeature
...../branch3
...../branchN
..../GUI
...../bugfix
...../newfeature
...../branch3
...../branchN

/tag
..../CLI
...../version 1.0
...../version 2.0
...../version n.n
..../GUI
...../version 1.0
...../version 2.0
...../version n.n

Or am I making this far too complicated? Would you recommend storing the GUI version in a separate repository? Also in which of these typical directories are precompiled executables stored?

I understand these questions may seem novice, but the truth is I'm completely new to SVN. Thank you for your help!

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

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

发布评论

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

评论(1

大海や 2024-11-16 06:18:22

我现在只使用 SVN 大约 3 或 4 年,你所拥有的对我来说看起来相当不错,我不会将 GUI 版本存储在单独的存储库中。在我的工作中,我们将所有项目都放在一个存储库下,只是不同的文件夹,这是有效的,因为正如您所说,您可以查看您想要的任何文件夹。

另外,还有一些人认为您不应该在 SVN 存储库中存储二进制数据(例如预编译的可执行文件),因为它会使存储库膨胀,因为它无法像文本一样与以前的版本进行比较。这或多或少是我工作中不成文的政策。在家里我的个人 SVN 上,我会签入我知道不会定期更改的重要可执行文件或库文件,以便在我需要时它们就在那里。我并不担心膨胀,并且能够退回到其他版本的 exe 有时候看到进展是很酷的。

就分支和标签而言,我从未使用过它们。我知道我可能应该这样做,但我的大多数项目无论如何都是“概念验证”,所以我的主干确实是我构建的全部。我基本上使用 SVN 作为一个非常好的备份和时间线工具。但我可能应该开始使用标签和分支。

I have been using SVN for only about 3 or 4 years now and what you have looks pretty good to me, I wouldn't store the GUI version in a separate repo. At my work we have all of our projects under one repo, just different folders and this works because as you stated you can check out whatever folders you want.

Also there are some people out there that argue that you shouldnt store binary data (such as precompiled executables) in an SVN repo simply because it will bloat the repo as it cannot be diffed with the previous version such like text can. This is more or less the unwritten policy at my work. At home on my personal SVN I will check in important executables or library files that I know wont change regularly, just so they are there when I need them. I am not worried about bloat, and being able to step back through the other version of the exe is kinda cool sometimes to see the progression.

As far as branches and tags go, I have never used them. I know I probably should, but most of my projects are 'proof of concept' anyways and so my main trunk is really all I build to. I basically use SVN as for a very nice backup and timeline tool. But I prob should start using tags and branches.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文