Open Cygwin at a specific folder

后端 未结 29 2578
悲哀的现实
悲哀的现实 2020-12-12 08:49

How can I create a Cygwin shortcut that will open Cygwin at a specific folder? This would obviate having to type

cd /cygdrive/c/Users/Tom/Desktop/

29条回答
  •  粉色の甜心
    2020-12-12 09:33

    based on @LindseyD answer I created a simple BAT file, that opens cygwin in current directory, it may be useful (for me it is). Assuming that You have cygwin's bin directory in PATH.

    FOR /F %%x IN ('sh -c pwd') DO bash -l -i -c 'cd %%x; exec bash'
    

提交回复
热议问题