2014-09-30 36 views
2

我試圖設置PowerShell作爲我的「Open Git-Shell」選項,但沒有成功。在命令字段中,我設置了以下選項:如何將PowerShell設置爲我的SmartGit「打開Git-Shell」命令?

命令:

powershell.exe 

參數:

-noexit -executionpolicy Unrestricted -command "cd '${filePath}'" 

這將在非交互模式下啓動PowerShell的(即:進程在任務管理器中運行,但UI不可見)。我究竟做錯了什麼?

+0

什麼調用命令行同時,會發生什麼? – mstrap 2014-09-30 08:02:15

+0

當我在命令行(cmd.exe)中直接運行命令時,PowerShell在命令窗口中運行,並將目錄更改爲指定的目錄。 – 2014-09-30 17:47:43

回答

2

我玩弄cmd.exe來調用PowerShell爲「Open Git-Shell」在SmartGit。我能得到與以下期望的結果:

命令:

cmd.exe 

參數:

/c start powershell.exe -noexit -executionpolicy Unrestricted -command "cd '${filePath}'" 
相關問題