如何在msysgit的bash中访问U盘
阿神
阿神 2017-04-28 09:05:08
0
1
685

我一直使用msysgit作为windows上的源代码解决方案。但在git bash中无法访问新插入的U盘盘符。这个问题应该如何解决呢?

问题说明:

在msysgit中,可以使用cd /c/【some directory】切换目录,但,使用cd /h会反馈sh.exe": cd: /h: No such file or directory

注: h为Windows识别出的U盘盘符。msysgit的版本是:git version 1.9.2.msysgit.0

阿神
阿神

闭关修行中......

reply all(1)
巴扎黑

Okay, the current method is:

  • Close all Bash windows
  • Restart Git Bash

You can now access the newly inserted USB flash drive.

PS: The solution suggested on Stackoverflow did not work on my computer.

Explanation

msysGit uses MinGW/Msys at the bottom level. In order to ensure program execution efficiency, the fstab information of the file system is created by the first Msys program and stored in memory. Only when all applications release their use of this fstab will the corresponding memory be released. This also explains why fstab is refreshed after closing all bash.

References

  • Bug: dynamically mounted USB drives inaccessible
  • Re: ANN: Git for Windows 1.7.0.2 preview 20100309
  • git bash does not access drive f:
  • How to register newly mounted drive in git bash?
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template