开发者

GIT: Get Bash Here on network location

开发者 https://www.devze.com 2023-01-11 04:05 出处:网络
When I do \'Get Bash Here\' on a network location the console isn\'t in that directory. Instead the directory is /c/Windows.

When I do 'Get Bash Here' on a network location the console isn't in that directory. Instead the directory is /c/Windows.

Is this a limitation of G开发者_如何学JAVAit Bash?


No, this is a limitation of Windows. The Windows "current directory" for a program cannot be UNC pathname, but must be a path with a drive letter. You will need to assign a drive letter to your network location.

You can either do this through the normal Windows Explorer method, or there's a shortcut command line to automatically create a drive letter:

pushd \\server\share\path

Run that in a usual Windows cmd shell, and it will allocate a new drive letter and change to it. Then you can use "Git Bash Here" on that drive letter and path from Windows Explorer.

0

精彩评论

暂无评论...
验证码 换一张
取 消