views:

99

answers:

2

I have PowerShell v2.0 installed and on top of that, PSCX is installed. PSCX is the PowerShell Community Extensions (http://pscx.codeplex.com/Wikipage).

It seems that I have two cmdlets called Start-Process installed and I'm guessing one is the original and the other is from PSCX. When I invoke Start-Process, the PSCX cmdlet is made to run. How can I make PowerShell run the original version instead?

Helpful Evidence:

When I run get-help start-process i get:

Name                              Category  Synopsis
----                              --------  --------
Start-Process                     Cmdlet    PSCX Cmdlet: Starts a new process.
Start-Process                     Cmdlet    Starts one or more processes on the local computer.

When I run get-command start-process I get:

CommandType     Name                                                          Definition
-----------     ----                                                          ----------
Cmdlet          Start-Process                                                 Start-Process [[-Path] <String>] [[-Arguments] <String>] [...
+1  A: 

I have these aliases set up:

new-alias start-pscxprocess pscx\start-process 
new-alias start-msprocess microsoft.powershell.management\start-process  
Mike Shepard
+3  A: 

If you grab the module-based version (PSCX 2.0 Beta), you can choose not to import the Pscx.Deprecated module which contains the three PSCX cmdlets that clash with the built-in PowerShell cmdlets: Start-Process, Select-Xml and Get-Random. Note the PSCX 2.0 Beta is an xcopy deploy requiring you to only do this:

  1. Download the Pscx-2.0-Beta2.zip
  2. Open its properties in Windows Explorer and press the Unblock located on the General tab. This is required otherwise you'll get a lot of errors when you import the module.
  3. Extract the files (preserving the folder structure) into ~\WindowsPowerShell\Modules
  4. Import-Module Pscx

That's it. If you need to re-enable the "Open PowerShell Here" context menu entry in Windows Explorer then run the command Enable-OpenPowerShellHere.

Keith Hill