git 在visualstudio.com上从tfs迁移到git
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/19548659/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Migrate from tfs to git on visualstudio.com
提问by Umair
I have a remote repository on visualstudio.com (a free account) but its on tfs, and I want to move it to git for visualstudio.com
我在visualstudio.com(一个免费帐户)上有一个远程存储库,但它在tfs 上,我想将它移至visualstudio.com 的git
Has anyone tried this yet?
有没有人试过这个?
I found this tutorial:
我找到了这个教程:
But in that there is a command git tfs clone http://tfs:8080/tfs/DefaultCollection $/TeamProject/git_folder
which copies from tfs to another folder and converts to git.
但其中有一个命令git tfs clone http://tfs:8080/tfs/DefaultCollection $/TeamProject/git_folder
可以从 tfs 复制到另一个文件夹并转换为 git。
How can I create a separate (git) folder in remote visualstudio.com server?
如何在远程 visualstudio.com 服务器中创建单独的 (git) 文件夹?
Also when doing this will it ask for my Windows Live id to authenticate or is there any command-line command?
此外,这样做时它会要求我的 Windows Live id 进行身份验证还是有任何命令行命令?
采纳答案by Umair
Got it working, correct command is to use https
without project name after DefaultCollection here for example:
得到它的工作,正确的命令是https
在 DefaultCollection 之后使用没有项目名称,例如:
git-tfs clone --username=mumair85 --password=xxxx https://mumair85.visualstudio.com/DefaultCollection $/uGen
回答by Edward Thomson
If you use the Git Credential Managerfor Windows (which is included in recent versions of Git for Windows), then it will prompt you to login to Visual Studio Team Services and set up authentication for you. You do not need to manually set up alternate authentication tokens.
如果您使用适用于 Windows的Git 凭据管理器(包含在适用于 Windows 的最新版本的 Git 中),它会提示您登录到 Visual Studio Team Services 并为您设置身份验证。您无需手动设置备用身份验证令牌。
To use git
(without the Git Credential Manager), git-tfs
or git-tf
, you'll need to set up Alternate Credentialsfor your Team Foundation Service account:
要使用git
(不使用 Git 凭证管理器)git-tfs
或git-tf
,您需要为您的 Team Foundation 服务帐户设置备用凭证:
- Click on your name in the upper right of any TFS web page
- Select the "Credentials" tab
- Select "Enable Alternate Credentials"
- Enter a new username and password combination
- 在任何 TFS 网页的右上角单击您的姓名
- 选择“凭据”选项卡
- 选择“启用备用凭据”
- 输入新的用户名和密码组合
You can then use this username/password combination for authentication from command-line applications.
然后,您可以使用此用户名/密码组合从命令行应用程序进行身份验证。