Git svn不使用svn凭据 [英] Git svn does not use the svn credentials

查看:184
本文介绍了Git svn不使用svn凭据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试从svn存储库克隆路径.该存储库已使用密码保护.

I try to clone a path from our svn repository. The repository is secured with passwords.

我在Windows 10系统上找到了一些Subversion目录,并为它们创建了符号链接.因此它只是一个目录.

I have found some subversion directories on my Windows 10 System and created symlinks for them. So it is only one directory.

我打开git-bash并启动命令

I opened the git-bash and started the command

svn checkout --username myuser --password mypassword svn://myserver/myrepository/myproject/trunk

SVN在auth/svn.simple目录中使用我的凭据创建了一个文件.文件以

SVN created in the auth/svn.simple directory a file with my credentials. The file starts with

K 8
passtype
V 8
wincrypt
K 8
password
...

以下命令现已成功:

svn update trunk

现在我要使用git-svn:

Now I want to use git-svn:

git svn clone svn://myserver/myrepository/myproject --username myuser

但是我得到的只是以下答复:

But all I get is the following response:

Initialized empty Git repository in D:/mylocalprojectpath/.git/
W: Item is not readable: Item is not readable at /mingw64/share/perl5/site_perl/Git/SVN.pm line 153.
**Error from SVN, (220001): Item is not readable: Item is not readable**

我所发现的有关此错误的所有信息都表明这是身份验证问题.因此在我看来git svn并不使用svn的存储凭据.

All I have found about this error says that this is an authentication problem. So it seems to me that git svn does not use the stored credentials of svn.

我做错了什么?有什么建议吗?

What am I doing wrong? Some suggestions?

推荐答案

git-svn不使用SVN的原因是它使用存储在C:\ Users \ XXXX.subversion中的凭据,该凭据是由git-svn创建的. SVN,但不是SVN. 就我而言,来自SVN的错误(220001):项目不可读:项目不可读.

The reason why git-svn does not use SVN is that it use the credentials stored at C:\Users\XXXX.subversion, which is created by git-svn but not SVN. In my case, Error from SVN, (220001): Item is not readable: Item is not readable also occur.

解决方案是将凭据从SVN移至git-svn:

The solution is to move the credentials from SVN to git-svn:

  1. 使用SVN从服务器中检出.记住要保存身份验证.这可以为SVN创建凭据.这些文件存储在C:\ Users \ XXXXX \ AppData \ Roaming \ Subversion中.
  2. 删除.subversion文件夹,该文件夹位于用户目录C:\ Users \ XXXXX下(如果存在).然后将C:\ Users \ XXXXX \ AppData \ Roaming \ Subversion文件夹复制到C:\ Users \ XXXXX.
  3. 然后将其重命名为.subversion.由于名称以."开头,因此您可能需要在cmd控制台中使用重命名"命令将其重命名.
  4. 最后,您可以使用git-svn克隆.

这篇关于Git svn不使用svn凭据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆