1

From Windows Explorer I want to launch a command-prompt window with the working directory the current folder in Explorer.

So far I:

  • copy the path from the explorer navigation bar
  • Windows+R: cmd to launch a cmd prompt
  • cd /d CTRL+V

But there must be a way to improve on this somewhat? Preferably without installing any extensions.

I'm running a pretty standard Windows 10 setup, slightly different versions across different machines so something that is standard would be best.

Mr. Boy
  • 5,554

2 Answers2

2

PowerShell

To open a PowerShell, you can hold down the Shift key and right click in blank space in the folder. There will be an option for "Open PowerShell window here": Screenshot of contextual menu

Command Prompt

You can type cmd into the address bar of Windows Explorer once you navigate to the folder you wish to be on command line for and hit Enter. A command prompt window will open up to that directory. Screenshot of launching cmd Then it will open: enter image description here

Narzard
  • 3,840
0

It seems to me a duplicate question, where several options are answered.

Anyway, take a look at this simple option...



  • So, save this code as file./, and run or click (need admin rights).
Windows Registry Editor Version 5.00;Command Prompt Here[HKEY_CLASSES_ROOT\Directory\shell\runas]@="Command Prompt Here"[HKEY_CLASSES_ROOT\Directory\shell\runas\command]@="cmd.exe /s /k pushd \"%V\""
cls & echo/ & "%__APPDIR__%reg.exe" import "%~f0" & "%__APPDIR__%timeout" -1 

  • This is the reg part of hybrid with / file:
Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\shell\runas]
@="Command Prompt Here"

[HKEY_CLASSES_ROOT\Directory\shell\runas\command]
@="cmd.exe /s /k pushd \"%V\""

  • You get this menu context: Command Prompt Here

  • You don't need additional startup script or holding Shift and Right-Click.

Io-oI
  • 9,237