Disable Windows Server 2012 cmd and PowerShell for clients
Cfg User - Administrative Templates - System - Deny Command Line Access
Prevents users from running the interactive command line Cmd.exe. This parameter also determines whether batch files (.cmd and .bat) can run on the computer.
If you enable this parameter and the user tries to open a command window, the system displays a message explaining that the parameter is preventing the action.
Note. Do not prevent the computer from running batch files if it uses logon, logoff, batch file startup or shutdown scripts, or for users using Terminal Services.
I have no idea about PowerShell anything.
source to share
Disable powershell access:
In the Group Policy window for these users, on the left side, scroll down to User Configuration> Administrative Templates> System> Don't Run Specified Windows Applications.
In the properties window that opens, select the Enabled option, and then click the Show button.
In the Show Content window add -> powershell.exe
source to share