简体   繁体   English

如果SVN信息库中有新的提交,则防止dcommit自动重新设置基准

[英]Prevent dcommit from automatically rebasing if there are new commits in the SVN repository

When running git svn dcommit , git-svn will automatically do the equivalent of git svn rebase if not all commits present in the SVN repository have integrated into the branch being committed. 运行git svn dcommit ,如果不是SVN信息库中存在的所有提交都已集成到要提交的分支中,则git-svn将自动执行git svn rebase的等效操作。 Is it possible to disable this behavior? 是否可以禁用此行为? I would like git svn docmmit to fail instead, like git push by default fails in a non-fast-forward push. 我想让git svn docmmit失败,就像默认情况下git push在非快进推送中失败。

I am talking about this behavior: 我正在谈论这种行为:

$ git svn dcommit
Committing to svn://[...]
    [lists committed files]
Committed r1857
    [lists changes in the repostiory since last rebase]
r1856 = 3062cfbe5c3ab56d5d6e16cadba55cfa73e35c6e (refs/remotes/svn/trunk)
    [lists differences between committed revision and latest repository revision]
r1857 = 3a57b29f6e5006925f0ab7ec931e9ecf3b64b11b (refs/remotes/svn/trunk)
W: d3fbaa461d5ef643e400be7f6727fe6ef89a9d26 and refs/remotes/svn/trunk differ, using rebase:
:040000 040000 16b8ed30058d274f5f57560e06f2e8598312e0b4 dbe9d86a21aee9f4832021436f489b8e3ed8ed6e M  [...]
First, rewinding head to replay your work on top of it...
Applying: [rebases commits that were not yet committed]

After that the rebased commits are automatically committed. 之后,重新提交的提交将自动提交。

您可能会尝试git svn fetchgit merge --ff-only <svn/branch>

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM