我想知道,当我通过SSH连接到我们的源代码管理服务器时,是否有人能深入了解为什么SmartGit没有这样做。GitBash表现良好。
背景:
我在网络上安装了一个源代码管理服务器,运行MSYSGit,WinSSH作为SSH服务器。它连接到AD来解析用户名等,我已经导入了所有的公共RSA密钥等等。
对我们来说,一个曲线-球,虽然Git是安装在‘C:\程序文件(x86)\Git’,我们的实际源代码位于'C:\Git',这是定期备份。
我已经将WinSSH配置为使所有SSH会话默认为'C:\Git‘作为它们的主文件夹,这是一个不错的选择。当我使用Git Bash连接到服务器时,它默认为'C:\Git‘。太完美了。
当我获得SmartGit (使用SmartGit SSH客户端)连接到同一个服务器时,使用url:
ssh://<server>/<folder>/<repo>我说这条路错了..。
C:\Program Files (x86)\Git\<folder>\<repo> .看上去不是仓库嗯,是的..。它应该在'C:\Git‘中查找它,而不是'C:\Program (x86)\Git’。
我不知道为什么SmartGit没有很好地设置这个设置,但是我认为默认的WinSSH设置被它的SSH客户机绕过了,因为它完全从'C:\Program (x86)\Git‘指定了整个路径。
我的问题:
有什么想法可以让SmartGit获得'C:\Program (x86)\Git‘路径?
这是我可以在某个地方设置的变量吗?
进一步信息(更新)
SmartGit的版本为3.0.4,但这个问题也出现在2.x中。
我已经在SmartGit应用程序日志中附加了一个失败实例(我很确定):
1782732 (2012-05-10 12:18:56,653) QThreadPoolThread 2 (smartgit.KL) INFO smartgit.core.executable -执行以下命令:"C:\Program“ls-远程ssh://initio-dev01/INIT/INIT.Framework.git参考/smartgit.core.executable/
1782732 (2012-05-10 12:18:56,653) QThreadPoolThread 2 (smartgit.KL) INFO smartgit.core.executable -目录中: null
1783049 (2012-05-10 12:18:56,970) QThreadPoolThread-8 (smartgit.aqT) INFO smartgit.server -接收命令: ssh
1786438 (2012-05-10 12:19:00,359) QThreadPoolThread-6 (smartgit.cR) INFO smartgit.command.logging - stderr:'C:/Program (x86)/ git /INIT/INIT.Framework.git‘似乎不是一个git存储库。
1786438 (2012-05-10 12:19:00,359) QThreadPoolThread-6 (smartgit.cR) INFO smartgit.core.command -致命:'C:/Program (x86)/ git /INIT/INIT.Framework.git‘似乎不是一个git存储库。
1786439 (2012-05-10 12:19:00,360)线程-29错误smartgit.ssh.trilead - com.trilead.ssh2.transport.TransportManager:接收线程:receiveLoop中的错误:套接字关闭
1786763 (2012-05-10 12:19:00,684) QThreadPoolThread-6 (smartgit.cR) INFO smartgit.command.logging - stderr:致命:远程终端意外挂起
1786763 (2012-05-10 12:19:00,684) QThreadPoolThread-6 (smartgit.cR) INFO smartgit.core.command -致命:远程结束意外挂断
1786772 (2012-05-10 12:19:00,693) QThreadPoolThread 2 (smartgit.KL)警告sg.command.ping - 'C:/Program (x86)/ git /INIT/INIT.Framework.git‘似乎不是一个git存储库,远程终端突然挂起smartgit.cn:'C:/Program (x86)/Git/INIT/INIT.Framework.git’似乎不是一个git存储库--远程终端意外挂起。
Smartgit.gG.a(原始文件:86)
在SourceFile git.ga.a(原始文件:63)
at SourceFile git.ga.a(原始文件:53)
Smartgit.ha.a(原始文件:57)
Smartgit.ahq.a(原始文件:26)
Smartgit.ahl.a(原始文件:39)
Smartgit.aL.a(原始文件:46)
at smartgit.aD.a git.aD.a(原始文件:41)
在smartgit.Kw.a git.Kw.a(原始文件:144)
在smartgit.KL.run(原始文件:34)
在smartgit.Pp.run(SourceFile:65)
发布于 2012-05-16 12:30:42
与硬编码的路径非常恼人,这似乎是这里的问题?!在以后的版本中修复之前,也许您应该创建一个目录连接点或符号链接。可能是一个(快速和肮脏的)解决方案,而不是花费时间来修复程序。
(必须在Administrator shell中运行)
接合点:
mklink /j "C:\Program Files (x86)\GIT\<folder>" C:\GIT\<folder>关于符号链接:
mklink /d "C:\Program Files (x86)\GIT\<folder>" C:\GIT\<folder>https://stackoverflow.com/questions/10527131
复制相似问题