簡體   English   中英

git svn-缺少svn提交?

[英]git svn - get missing svn commits?

我使用的是Ubuntu 14.04,git-svn版本1.9.1(svn 1.8.8)。 我試圖使用以下方法克隆https://sourceforge.net/p/searchmonkey/code/HEAD/tree/

git svn clone https://svn.code.sf.net/p/searchmonkey/code -T trunk -b branches -t tags --prefix=origin/ searchmonkey-code-svngit

該過程如下所示結束:

...
r850 = 3b98c1c32c0043184313828780c02ed7c2d85a7e (refs/remotes/origin/shawno)
    M   searchmonkey_2_x_x/util.h
    M   searchmonkey_2_x_x/mainwindow.ui
    M   searchmonkey_2_x_x/tab.cpp
    M   searchmonkey_2_x_x/mapped.cpp
    M   searchmonkey_2_x_x/find.h
    M   searchmonkey_2_x_x/grep.cpp
    M   searchmonkey_2_x_x/matcher.cpp
    M   searchmonkey_2_x_x/matcher.h
    M   searchmonkey_2_x_x/mainwindow.cpp
r851 = b3fe25fdacad270432f1a2f7b5876b83b54d2387 (refs/remotes/origin/shawno)
Checked out HEAD:
  https://svn.code.sf.net/p/searchmonkey/code/trunk r365
error closing pipe: Bad file descriptor at /usr/lib/git-core/git-svn line 0.
error closing pipe: Bad file descriptor at /usr/lib/git-core/git-svn line 0.

現在,當我對cd searchmonkey-code-svngit並發出gitk --all ,我看到最新的提交是r851,我已將master復位到該位置。 因此,現在的狀態是:

$ git svn info
Path: .
URL: https://svn.code.sf.net/p/searchmonkey/code/branches/shawno
Repository Root: https://svn.code.sf.net/p/searchmonkey/code
Repository UUID: 937bcc44-791b-0410-a411-b6e56c9656c8
Revision: 851
Node Kind: directory
Schedule: normal
Last Changed Author: shawno
Last Changed Rev: 851
Last Changed Date: 2011-05-06 04:01:08 +0200 (Fri, 06 May 2011)
$ git status
On branch master
nothing to commit, working directory clean
$ git log -1
commit b3fe25fdacad270432f1a2f7b5876b83b54d2387
Author: shawno <shawno@937bcc44-791b-0410-a411-b6e56c9656c8>
Date:   Fri May 6 02:01:08 2011 +0000

    minor changes before move working copy to non-system drive

    git-svn-id: https://svn.code.sf.net/p/searchmonkey/code/branches/shawno@851 937bcc44-791b-0410-a411-b6e56c9656c8
$ git svn log -1
------------------------------------------------------------------------
r851 | shawno | 2011-05-06 04:01:08 +0200 (Fri, 06 May 2011) | 2 lines

minor changes before move working copy to non-system drive

------------------------------------------------------------------------

...但是,sourceforge頁面顯示:

標簽2011-05-07 shawno [r852] 2.0.1從未發布

...因此,基本上,我在此項目的Sourceforge svn中缺少r852,因為git svn克隆的最后一個是r851。 我試着做:

$ git svn fetch
$ git svn rebase
Current branch master is up to date.
creating empty directory: install_msi/cache.upx/tmp
creating empty directory: sm_no_gui/release
$ git svn rebase
Current branch master is up to date.

……不過,最新的提交是r851。

如何將丟失的r852提交到git svn存儲庫中?

啊,我想我明白了:如果我單擊[r852] 2.0.1從未發布 ,那么我可以看到:

已刪除/tags/searchmonkey_v2.0.1 /tags/searchmonkey_v2.0.1文件已刪除。

...因此這是一個條目,說明文件已被刪除; 否則,在https://sourceforge.net/p/searchmonkey/code/852/tree/上branches項目顯示:

分支機構2011-05-06 shawno [r851]進行細微更改,然后再將工作副本移至非...

...的確,r851 最新版本-一切都很好...

在git-svn克隆中,刪除標簽或分支的SVN提交將不可見。 但是您應該看到效果,因為應該刪除標記或分支,或者至少將其重命名為明確表示已在SVN中刪除的名稱,但我不確定100%。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM