git svn clone创建的额外分支 [英] extra branches created by git svn clone
问题描述
Continuing from my previous question I decided to go ahead and reclone the thing :
$ git svn clone --branches=Branches/Wrye\ Bash/* \
--tags=Tags/Wrye\ Bash/* \
--trunk=Programs/Wrye\ Bash/ --prefix=svn/ \
--ignore-paths="^(?:Releases|Projects|Scripts|Games|)/|^Programs/\
(?:Nif Scanner|Nif Viewer|Raziel23x's Oblivion Toolset|Shader Disasm|Shader Editor)/" \
--authors-file=authors_with_emails.txt \
svn://svn.code.sf.net/p/oblivionworks/code/ . >> 2013.07.28 2>&1
所以现在我只克隆了一个带有其分支和标签的特定项目
So now I only cloned a particular project with its branches and tags
结果:
$ git branch -a
* master
remotes/svn/291-fixes
remotes/svn/294.2%20bugfixes
remotes/svn/294.2-3329021
remotes/svn/295-3329021
remotes/svn/295-fixes
remotes/svn/296-unicode
remotes/svn/302-fixes
remotes/svn/dev-sharlikran
remotes/svn/tags/274
remotes/svn/tags/276
remotes/svn/tags/288
remotes/svn/tags/289
remotes/svn/tags/290
remotes/svn/tags/291
remotes/svn/tags/291.1
remotes/svn/tags/292
remotes/svn/tags/293
remotes/svn/tags/294
remotes/svn/tags/294.1
remotes/svn/tags/294.1.test
remotes/svn/tags/294.2
remotes/svn/tags/295
remotes/svn/tags/295.1
remotes/svn/tags/295.2
remotes/svn/tags/295.3
remotes/svn/tags/295.4
remotes/svn/tags/295.5
remotes/svn/tags/296
remotes/svn/tags/297
remotes/svn/tags/297.1
remotes/svn/tags/298
remotes/svn/tags/299
remotes/svn/tags/300
remotes/svn/tags/301
remotes/svn/tags/302
remotes/svn/tags/302.1
remotes/svn/tags/302a
remotes/svn/tags/303
remotes/svn/tags/304
remotes/svn/trunk
但是 Branches/Wrye \ Bash/文件夹仅包含:
291-fixes
294.2-3329021
295-fixes
302-fixes
dev-sharlikran
那么remotes/svn/294.2%20bugfixes
,remotes/svn/295-3329021
和remotes/svn/296-unicode
从哪里弹出?
r1947 = 435203c3dc4c8a608e3a33d325afd2013549fd34 (refs/remotes/svn/trunk)
Found possible branch point: svn://svn.code.sf.net/p/oblivionworks/code/Programs/Wrye%20Bash => svn://svn.code.sf.net/p/oblivionworks/code/Branches/Wrye%20Bash/296-unicode, 1947
Found branch parent: (refs/remotes/svn/296-unicode) 435203c3dc4c8a608e3a33d325afd2013549fd34
Following parent with do_switch
Successfully followed parent
r1948 = c5e6069b46f9501478e0f354c9956092be3e407f (refs/remotes/svn/296-unicode)
M Mopy/bash_default.ini
# etc
完整日志.
另一个问题:我应该为这些分支创建本地分支吗?
忘了提一下,我现在打算将其作为git-svn的桥梁,但最终将其作为完整的迁移-所以我想尽可能正确地做到这一点
EDIT :
Another question : Should I create local branches for those ?
Forgot to mention I intent this as a git-svn bridge for now but eventually as a complete migration - so I want to do it as correctly as possible
注意,我不是在谈论 @分支机构
推荐答案
那么remotes/svn/294.2%20bug修复程序,remotes/svn/295-3329021和remotes/svn/296-unicode从哪里弹出?
So where did the remotes/svn/294.2%20bugfixes, remotes/svn/295-3329021 and remotes/svn/296-unicode pop from ?
从SVN仓库:-).认真地说,这些分支存在于分支/黑麦猛击"下,但后来在SVN中被删除.
From the SVN repo :-). Seriously, these branches existed under "Branches/Wrye Bash", but they were deleted later in SVN.
如果在SVN信息库中删除了一个分支,则git-svn
不会删除相应的git分支(因为否则该分支及其所有[未合并]提交将在git中丢失).
If a branch is deleted in the SVN repository, git-svn
will not delete the corresponding git branch (because otherwise the branch and all its [unmerged] commits would be lost in git).
如果这些分支困扰您,则必须手动将其删除.参见例如如何使git-svn摆脱不再存在的远程分支?
If these branches bother you, you'll have to delete them manually. See e.g.How can I make git-svn get rid of remote branches that don't exist anymore?
另一个问题:我应该为那些人创建本地分支吗?
EDIT : Another question : Should I create local branches for those ?
通常,只有要提交到本地分支,才创建它.因此,无需提前创建本地分支机构,就可以在需要处理的分支机构上进行创建.
Usually, you only create a local branch if you want to commit to it. So there's no need to create local branches in advance, you can do it once you want to work on it.
这篇关于git svn clone创建的额外分支的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!