Substitute windows cmd
I found PowerCmd.开发者_运维百科 And would like to substiture cmd - as default IDE for execution of bat files. But simple replacin of comspec do nothing. I cann't also rename cmd.exe in %SYSTEM32%. Is possible to substiture or not? Thanks.
I am giving answer for Powershell, should be similar for anything else that you want to use:
Use Regedit and goto
HKEY_CLASSES_ROOT\batfile\shell\open\command
Set the default value to
C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe -noexit "%1" %*
Now when you double click on any batch file, it should run on powershell. -noexit
gets to the powershell prompt after completion of the batch file.
精彩评论