SVN:将挂起的更改移至新分支

发布于 2024-10-05 11:14:11 字数 477 浏览 0 评论 0原文

源代码具有本地修改,不得将其提交到主干,而是提交到尚不存在的分支。

这是 svn info 显示的内容:(

Pfad: .
URL: svn://10.8.0.1/fx_dev
Basis des Projektarchivs: svn://10.8.0.1/fx_dev
UUID des Projektarchivs: 6279aca8-1485-11de-bcb4-29f147300bdb
Revision: 859
Knotentyp: Verzeichnis
Plan: normal
Letzter Autor: andy_svn
Letzte geänderte Rev: 859
Letztes Änderungsdatum: 2010-12-02 15:08:11 +0100 (Do, 02. Dez 2010)

这是德语,但我想您仍然理解它)

如何创建一个分支并将挂起的更改移动到该分支上?

Source code has local modifications that must not be committed to the trunk, but rather to a branch that does not yet exist.

This is what svn info shows:

Pfad: .
URL: svn://10.8.0.1/fx_dev
Basis des Projektarchivs: svn://10.8.0.1/fx_dev
UUID des Projektarchivs: 6279aca8-1485-11de-bcb4-29f147300bdb
Revision: 859
Knotentyp: Verzeichnis
Plan: normal
Letzter Autor: andy_svn
Letzte geänderte Rev: 859
Letztes Änderungsdatum: 2010-12-02 15:08:11 +0100 (Do, 02. Dez 2010)

(It's German, but I guess you still understand it)

How can I create a branch and move the pending changes onto that branch?

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

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

发布评论

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

评论(3

别忘他 2024-10-12 11:14:11

创建一个分支

svn copy URL/trunk URL/branches/B_NAME -m"- New Branch"

通过make

svn switch URL/branches/B_NAME

,然后提交更改

这是有效的,因为复制发生在服务器上,而不是客户端上。切换到新分支时,svn switch 命令不会覆盖本地更改。

Create a branch via

svn copy URL/trunk URL/branches/B_NAME -m"- New Branch"

make an

svn switch URL/branches/B_NAME

and then commit your changes.

This works because the copy happens on the server, not the client. The svn switch command will not overwrite changes locally when switching over to the new branch.

↘紸啶 2024-10-12 11:14:11

几乎您需要了解的有关 SVN 的所有内容都在红皮书中(链接)。除非您有具体问题,也许是说您已经尝试过的内容,否则您应该参考它。

创建分支

http://svnbook。 red-bean.com/en/1.1/ch04s02.html#svn-ch-4-sect-2.1

svn 切换命令

http://svnbook.red-bean.com/en/1.0/re27.html

Pretty much everything you ever need to know about SVN is in the red book (linked). Unless you have a specific question, maybe saying what you have tried already, it is what you should refer to.

Create a branch

http://svnbook.red-bean.com/en/1.1/ch04s02.html#svn-ch-4-sect-2.1

the svn switch command

http://svnbook.red-bean.com/en/1.0/re27.html

酒儿 2024-10-12 11:14:11

我现在遇到了问题:服务器端目录结构完全错误,缺少TTB(主干、标签、分支)目录。我改变了,现在一切都很好!

我不知道主干、标签和分支是存储库中每个人都可以添加和删除的实际目录,我一直认为它们是由 SVN 不可更改地提供的。

I got the problem now: The server-side directory structure was completely wrong and missing the TTB (trunk, tags, branches) directories. I changed that and now everything's fine!

I didn't know trunk, tags and branches were actual directories in the repo everybody could add and delete, I always thought they were immutably provided by SVN.

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