-
Notifications
You must be signed in to change notification settings - Fork 766
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fatal: ''<path>'' does not appear to be a git repository #1237
Comments
@luckerby, as far as I remember, powershell can interpret the single quoted string. If you config powershell as default shell on the server side, I expect that you don't need to apply the workaround. |
@luckerby, I tried to set the defaultShell, no need to apply the workaround:
|
@bingbing8 I tried your workaround. The server return:
I turned on debugging environment variables and git clone again:
I've got this:
Do you know what's going on? |
@doggy8088, setting to powershell works for me. |
@bingbing8, sorry for the late reply. Your solution works perfectly - just tested. Extra bonus point - Jenkins can now connect to OpenSSH for git integration; I wouldn't have been able to apply the previous workaround in the Jenkins git dialog. |
@doggy8088, i have a same problem after install PowerShell as a default shell, it is not work :( |
I didn't try with PowerShell as suggested, I'm sure it works. However, I would like to keep using GitBash and be able to make the clone remote work. Any direction is appreciated. |
My problem is this: fatal: '/F:/Path/To/Repo.git' does not appear to be a git repository It seems to me the "/" before F is the problem... Why are you able to use "git clone user@opensshserver:c:/ScriptRepo"? I have to put "/" in front of my drive to connect... |
Hello, I tried to change the defaultshell to powerShell but every time I did the service stoped working, then It did not work again until I change the registry back and rebooted. |
We recommend using PowerShell, or if you need to use Bash, use the copy of SSH that comes with git |
"OpenSSH for Windows" version
7.7.2.0
Server OperatingSystem
Windows Server 2016 Standard
Client OperatingSystem
Windows 10 Version 1803 (OS Build 17134.167)
Expected output
$ git clone user@opensshserver:c:/ScriptRepo
Cloning into 'ScriptRepo'...
remote: Counting objects: 10, done.
remote: Total 10 (delta 0), reused 0 (delta 0), pack-reused 10
Unpacking objects: 100% (10/10), done.
Actual output
$ git clone user@opensshserver:c:/ScriptRepo
Cloning into 'ScriptRepo'...
fatal: ''c:/ScriptRepo'' does not appear to be a git repository
fatal: Could not read from remote repository.
This issue has been discussed previously here, and the mentioned workaround works just fine once a remote is created. However this needs to be applied on each client machine, and it also prevents simple commands such as git clone - given that the setting of invoking powershell along with git-upload-pack can only be done once the remote has been created. Is there a plan to have this fixed, or is a way to specify the "default shell" that's "passed" along as being Powershell, thus solving the double single-quote issue ?
The text was updated successfully, but these errors were encountered: