How to start MingW Console (GitBash) from Command Line on Windows?

点点圈 提交于 2019-12-03 02:59:07
VonC

git-bash.exe -i -c "/bin/bash" seems to work better.
This issue illustrates various other ways to call git-bash.exe, but concludes:

Preferred way to run git-for-windows is using git-cmd.exe:

c:\git\git-cmd.exe --command=usr/bin/bash.exe -l -i

That however only opens a session in the current cmd, while git-bash.exe opens a new windows.

Combined with this question (to open a new console) and this one (to avoid two CMD windows), I would use:

start /b cmd /c git-bash.exe -i -l -c "/bin/bash"

The OP Atif Mohammed Ameenuddin reports in the comments this as working fine:

start "" "%ProgramFiles%\Git\git-bash.exe"
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!