I'm trying to build a cmd
interactive function in Emacs, which would open a Windows command prompt - exactly like Win+R
cmd
does. Within Emacs, it would be accessible with M-x
cmd
, and it would open the Windows terminal on the current folder.
The reason I want to build this function is that there are cases where the Emacs shell does not give the outputs properly (see this), and in these cases I'd like to open a Windows terminal quickly, and at the location I'm at.
I know how to get the current folder in Emacs, but I can't seem to find how to launch the Windows console from Emacs. call-process
works for programs like firefox.exe or explorer.exe, yet when I try the following, nothing appears (it doesn't matter if I write the full path or not):
(call-process "cmd.exe")
TL;DR: So, what would be the command to launch, from Emacs, an external command prompt at a specific path?