[英]What is wrong in my syntax?(batch file to migrate from git to svn)
I need to migrate some git repositories to subversion. 我需要将一些git存储库迁移到Subversion。
Some of the projects have a lot of history which i want to preserve. 我想保留一些项目的悠久历史。 Also the author names have to stay the same.
同样,作者姓名必须保持不变。
After tinkering around and searching for other ways to achieve this, i still cant seem to get it to work properly. 在修补并寻找其他方法来实现这一目标之后,我似乎仍然无法使其正常工作。
The git repository i need to migrate is a local repository on my c drive. 我需要迁移的git存储库是c驱动器上的本地存储库。 The svn server i need to migrate these repositories to is on the local network.
我需要将这些存储库迁移到的svn服务器位于本地网络上。
This is what i came up with so far: 到目前为止,这是我想出的:
svn mkdir --parents SVNSERVER/DestinationRep
git svn clone -sA authors.file svn://LocalSourceFolder
cd LocalSourceFolder
git remote add origin localSourceFolderPath
git fetch origin
git checkout -b old_master origin/master
git rebase --onto master --root
git svn dcommit
pause
when i try to execute, its also shows this error: 当我尝试执行时,它也会显示此错误:
"Unable to determine upstream SVN information from HEAD history." “无法从HEAD历史记录中确定上游SVN信息。”
now, before people tell me, i know similar questions have been asked here before, i read a lot of them, but they dont seem to provide the missing ´key´ that would make this work. 现在,在人们告诉我之前,我知道这里曾经问过类似的问题,我读了很多,但是它们似乎并没有提供使这项工作可行的缺少的“钥匙”。
Any help is appreciated. 任何帮助表示赞赏。
Console output: 控制台输出:
svn mkdir --parents h
ttp://192.168.10.106/svn/Itp-tools/BackupUploader
svn: E205007: Konnte keinen externen Editor zur Eingabe der Logmeldung bestimmen
. Setzten Sie entweder die $SVN_EDITOR Umgebungsvariable oder verwenden Sie die
--message (-m) oder --file (-F) Optionen
svn: E205007: Keine der Umgebungsvariablen SVN_EDITOR, VISUAL oder EDITOR ist ge
setzt und keine Laufzeitkonfigurationsoption »editor-cmd« wurde gefunden
git svn clone -sA auth
ors.file svn://BackupUploader
Can't open authors.file No such file or directory
-- i can handle this when other errors are resolved
cd BackupUploader
git remote add origin C:\Users\msc\Desktop\git-tf-2.0.2.20130214\BackupUploader
git fetch origin
From C:\Users\msc\Desktop\git-tf-2.0.2.20130214\BackupUploader
* [new branch] master -> origin/master
git checkout -b old_master origin/master
Branch old_master set up to track remote branch master from origin.
Switched to a new branch 'old_master'
git rebase --onto master --root
First, rewinding head to replay your work on top of it...
Fast-forwarded old_master to master.
git svn dcommit
Unable to determine upstream SVN information from HEAD history.
Perhaps the repository is empty. at C:\Program Files\Git\mingw64/libexec/git-cor
e\git-svn line 866.
Less important 不太重要
-m
-m
添加提交消息(创建文件夹为 commit) More important 更重要
http://192.168.10.106/svn/Itp-tools/BackupUploader
and svn://BackupUploader
?! http://192.168.10.106/svn/Itp-tools/BackupUploader
和svn://BackupUploader
吗?
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.