Monday, January 22, 2018

Why Powershell will not replace Windows DOS shell/command (CMD.exe) line, 2018 update

Now that Window CU replaced DOS shell (CMD.exe) with Powershell as the default shell, there is some speculation of getting ride of DOS altogether ! 
That will not happen for some time, the DOS shell (CMD.exe) will remain and here is one simple reason why. 

Until there's a Powershell equivalent to making symbolic soft-links, junctions and hard-links, the DOS command line is here to stay. 

MKLINK is used to to create symbolic soft-links, junctions and hard-links. 
You can call the mklink provided by cmd, from PowerShell to make symbolic links:
cmd /c mklink c:\path\to\symlink c:\target\file
You must pass /d to mklink if the target is a directory.

Full MKLINK man page.

No comments:

Post a Comment