搜尋

首頁  >  問答  >  主體

git svn checkout 時 分支的某個revision反覆checkout出來,該怎麼辦?

如下方所示的例子,由於原先SVN被人為的誤刪誤移過,導致revision其實不是很規範

然後用 git svn 時 某個特定的revision會被不停的checkout出來,由於用的Windows平台,已經超過文件路徑的最大值,導致不能順利checkout,不知道 有沒有同學對這方面有經驗?

refs/remotes/origin/Some_Branch@21
refs/remotes/origin/Some_Branch@21-
refs/remotes/origin/Some_Branch@21--
refs/remotes/origin/Some_Branch@21---
refs/remotes/origin/Some_Branch@21----
refs/remotes/origin/Some_Branch@21-----
refs/remotes/origin/Some_Branch@21------
refs/remotes/origin/Some_Branch@21-------
refs/remotes/origin/Some_Branch@21--------
refs/remotes/origin/Some_Branch@21---------
refs/remotes/origin/Some_Branch@21----------
refs/remotes/origin/Some_Branch@21-----------
refs/remotes/origin/Some_Branch@21------------
refs/remotes/origin/Some_Branch@21-------------
refs/remotes/origin/Some_Branch@21--------------
refs/remotes/origin/Some_Branch@21---------------
refs/remotes/origin/Some_Branch@21----------------
refs/remotes/origin/Some_Branch@21-----------------
refs/remotes/origin/Some_Branch@21------------------
refs/remotes/origin/Some_Branch@21-------------------
refs/remotes/origin/Some_Branch@21--------------------
refs/remotes/origin/Some_Branch@21---------------------
refs/remotes/origin/Some_Branch@21----------------------
refs/remotes/origin/Some_Branch@21-----------------------
refs/remotes/origin/Some_Branch@21------------------------
refs/remotes/origin/Some_Branch@21-------------------------
refs/remotes/origin/Some_Branch@21--------------------------
refs/remotes/origin/Some_Branch@21---------------------------
refs/remotes/origin/Some_Branch@21----------------------------
refs/remotes/origin/Some_Branch@21-----------------------------
refs/remotes/origin/Some_Branch@21------------------------------
refs/remotes/origin/Some_Branch@21-------------------------------
refs/remotes/origin/Some_Branch@21--------------------------------
refs/remotes/origin/Some_Branch@21---------------------------------
refs/remotes/origin/Some_Branch@21----------------------------------
refs/remotes/origin/Some_Branch@21-----------------------------------
refs/remotes/origin/Some_Branch@21------------------------------------
refs/remotes/origin/Some_Branch@21-------------------------------------
refs/remotes/origin/Some_Branch@21--------------------------------------
refs/remotes/origin/Some_Branch@21---------------------------------------
refs/remotes/origin/Some_Branch@21----------------------------------------
refs/remotes/origin/Some_Branch@21-----------------------------------------
refs/remotes/origin/Some_Branch@21------------------------------------------
refs/remotes/origin/Some_Branch@21-------------------------------------------
refs/remotes/origin/Some_Branch@21--------------------------------------------
refs/remotes/origin/Some_Branch@21---------------------------------------------
refs/remotes/origin/Some_Branch@21----------------------------------------------
refs/remotes/origin/Some_Branch@21-----------------------------------------------
...省略N行

update:
樓主考慮的是從svn遷移到git,所以要盡量保留提交記錄

update:
樓主用了 --no-metadata 參數

伊谢尔伦伊谢尔伦2770 天前861

全部回覆(1)我來回復

  • 给我你的怀抱

    给我你的怀抱2017-05-02 09:28:11

    可以在clone的時候添加,--revision,指定從哪個svn版本開始clone。

    回覆
    0
  • 取消回覆