Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is the Powershell backwards compatible with the standard command prompt? [closed]

Is there any potential issues with using the powershell but executing all the traditional commands associated with the old Windows command shell? I am also concerned that batch files written in the old style remain unaffected.

It makes complete sense that Microsoft will have thought of all of this; however, I just need to be cautious as we are running old style scripts in a production environment. I don't want to worry that powershell might pose any issues.

We are scheduling jobs (running batch files) via Windows Task Scheduler. I assume these jobs will be just fine whether the files are run as though submitted via the Powershell.

like image 450
Mario Avatar asked Oct 11 '13 15:10

Mario


People also ask

Is PowerShell compatible with CMD?

It is not only an interface but also a scripting language that is used to carry out administrative tasks more easily. Most of the commands executed on cmd can be run on PowerShell as well.

Does PowerShell support all CMD commands?

Yes, kind of. Powershell sometimes use different syntax for the commands, so if you have specific commands you often use in CMD, you might want to do a quick search for those first. Most commands are the same though.

Is PowerShell core backwards compatible?

PowerShell 7.0 marks a move a to . NET Core 3.1, enabling significantly more backwards compatibility with existing Windows PowerShell modules. This includes many modules on Windows that require GUI functionality like Out-GridView and Show-Command , as well as many role management modules that ship as part of Windows.


1 Answers

No it is not completely backwards compatible. You can however run a cmd session within powershell then get compatibility. If you are running a batch file as a scheduled task, then the batch file would be processed in a cmd session and not powershell anyway so they shouldn't have an issue.

like image 121
EBGreen Avatar answered Nov 15 '22 04:11

EBGreen