How to find out what’s new in PowerShell vNext

Windows 8 Developer Preview (pre-beta version) was released for public at the BUILD conference (you can download it HERE) and it is packaged with PowerShell v3 and a ton of goodies! One aspect that I usually check when a new version is released is which new cmdlets were added and what parameters has been added or removed.

To find all the changes between the two versions of PowerShell (v2 and v3) I put together a script that produces a list of commands and parameters. To compare the changes I run a command, on each version of PowerShell , that exports all core cmdlets (cmdlet name and a list of parameters) to an XML file using the Export-CliXml cmdlet.

Once the XML files have been created I import them back using the Import-CliXml cmdlet and then look at the differences. The script can be used, with some modifications, to find differences in other areas too- aliases, automatic and environment variables, specific module cmdlets and so on. Take the time to experiment with it.

 

UPDATE

There seems to be an issue with the command I used to export cmdlets and parameters in Windows 8 (works fine in v2).
For some reason, some cmdlets do not have a value in the Parameters column.
To resolve this I modified the expression to get the parameters and added a second call to Get-Command.
The new expression I used (post code is updated as well as the result).  @mjolinor, thanks :for the comment!

Get-Command -Module Microsoft.PowerShell.*, Microsoft.WSMan.* | Select-Object -Property Name,@{Name=’Parameters’;Expression={(Get-Command $_).Parameters.Keys}}

The old expression was: … ;Expression={$_.Parameters.Keys}}

Here’s the result. Yummy! 🙂

Legend
——–
!  > Changed
+ > New
–  > Removed

Add-Computer (!)
ComputerName (+)
Force (+)
LocalCredential (+)
NewName (+)
Options (+)
Restart (+)
UnjoinDomainCredential (+)Add-Content (!)
Stream (+)Add-Member (!)
NotePropertyMembers (+)
NotePropertyName (+)
NotePropertyValue (+)
TypeName (+)

Add-Type (!)
LiteralPath (+)

Clear-Content (!)
Stream (+)

Export-Alias (!)
LiteralPath (+)

Export-Clixml (!)
LiteralPath (+)

Export-Csv (!)
Append (+)
LiteralPath (+)

Export-FormatData (!)
LiteralPath (+)

Export-PSSession (!)
Certificate (+)

ForEach-Object (!)
ArgumentList (+)
Confirm (+)
MemberName (+)
RemainingScripts (+)
WhatIf (+)

Get-Acl (!)
AllCentralAccessPolicies (+)
InputObject (+)
LiteralPath (+)

Get-AuthenticodeSignature (!)
LiteralPath (+)

Get-ChildItem (!)
Attributes (+)
Directory (+)
File (+)
Hidden (+)
ReadOnly (+)
System (+)

Get-Command (!)
All (+)

Get-Content (!)
Raw (+)
Stream (+)
Tail (+)

Get-Date (!)
Millisecond (+)

Get-Item (!)
Stream (+)

Get-Job (!)
After (+)
Before (+)
Filter (+)
Newest (+)

Get-Module (!)
Authentication (+)
CimSession (+)
ComputerName (+)
Credential (+)
PSSession (+)

Get-PfxCertificate (!)
LiteralPath (+)

Get-PSSession (!)
Authentication (+)
CertificateThumbprint (+)
Credential (+)
Port (+)
State (+)
ThrottleLimit (+)
UseSSL (+)

Import-Alias (!)
LiteralPath (+)

Import-Clixml (!)
First (+)
IncludeTotalCount (+)
LiteralPath (+)
Skip (+)

Import-Csv (!)
Encoding (+)
LiteralPath (+)

Import-LocalizedData (!)
PassThru (+)

Import-Module (!)
AsWorkflow (+)
Authentication (+)
CimSession (+)
ComputerName (+)
Credential (+)
MinimumVersion (+)
NoClobber (+)
PSSession (+)
RequiredVersion (+)
Scope (+)
Version (-)

Import-PSSession (!)
Certificate (+)

Invoke-Command (!)
Disconnected (+)
SessionName (+)

New-ModuleManifest (!)
DefaultCommandPrefix (+)
DependentWorkflows (+)
ExportAsWorkflow (+)
HelpInfoUri (+)
ModuleToProcess (-)
RootModule (+)
WorkflowsToProcess (+)

New-PSSessionOption (!)
OutputBufferingMode (+)

Out-File (!)
LiteralPath (+)

Out-GridView (!)
Block (+)
OutputMode (+)
PassThru (+)

Receive-Job (!)
Wait (+)
WriteEvents (+)
WriteJobInResults (+)

Register-PSSessionConfiguration (!)
AccessMode (+)
ModulePath (+)
Path (+)
PSVersion (+)
RunAsCredential (+)
SessionType (+)
SessionTypeOption (+)
TransportOption (+)
UseSharedProcess (+)

Remove-Computer (!)
ComputerName (+)
Credential (-)
LocalCredential (+)
Restart (+)
UnjoinDomainCredential (+)
Workgroup (+)

Remove-Item (!)
Stream (+)Remove-Job (!)
Filter (+)Rename-Item (!)
LiteralPath (+)

Reset-ComputerMachinePassword (!)
Credential (+)

Restart-Computer (!)
Delay (+)
For (+)
Timeout (+)
Wait (+)

Select-Object (!)
Wait (+)

Select-String (!)
LiteralPath (+)

Select-Xml (!)
LiteralPath (+)

Set-Acl (!)
CentralAccessPolicy (+)
ClearCentralAccessPolicy (+)
InputObject (+)
LiteralPath (+)
SecurityDescriptor (+)

Set-AuthenticodeSignature (!)
LiteralPath (+)

Set-Content (!)
Stream (+)

Set-PSSessionConfiguration (!)
AccessMode (+)
ModulePath (+)
PSVersion (+)
RunAsCredential (+)
SessionType (+)
SessionTypeOption (+)
TransportOption (+)
UseSharedProcess (+)

Set-WSManQuickConfig (!)
SkipNetworkProfileCheck (+)

Start-Job (!)
DefinitionName (+)
DefinitionPath (+)
DefinitionType (+)
LiteralPath (+)
PSVersion (+)
WriteToStore (+)

Start-Transcript (!)
LiteralPath (+)

Stop-Job (!)
Filter (+)

Tee-Object (!)
Append (+)
LiteralPath (+)

Test-Path (!)
NewerThan (+)
OlderThan (+)

Update-TypeData (!)
DefaultDisplayProperty (+)
DefaultDisplayPropertySet (+)
DefaultKeyPropertySet (+)
Force (+)
InheritPropertySerializationSet (+)
InputObject (+)
MemberName (+)
MemberType (+)
PropertySerializationSet (+)
SecondValue (+)
SerializationDepth (+)
SerializationMethod (+)
StringSerializationSource (+)
TargetTypeForDeserialization (+)
TypeAdapter (+)
TypeConverter (+)
TypeData (+)
Value (+)

Wait-Job (!)
Filter (+)

Where-Object (!)
CContains (+)
CEQ (+)
CGE (+)
CGT (+)
CIn (+)
CLE (+)
CLike (+)
CLT (+)
CMatch (+)
CNE (+)
CNotContains (+)
CNotIn (+)
CNotLike (+)
CNotMatch (+)
Contains (+)
EQ (+)
GE (+)
GT (+)
In (+)
Is (+)
IsNot (+)
LE (+)
Like (+)
LT (+)
Match (+)
NE (+)
NotContains (+)
NotIn (+)
NotLike (+)
NotMatch (+)
Property (+)
Value (+)

Connect-PSSession (+)

ConvertFrom-Json (+)

ConvertTo-Json (+)

Disable-PSRemoting (+)

Disconnect-PSSession (+)

Export-CimCommand (+)

Get-ControlPanelItem (+)

Get-TypeData (+)

Invoke-RestMethod (+)

Invoke-WebRequest (+)

New-PSSessionConfigurationFile (+)

New-PSTransportOption (+)

New-WinEvent (+)

Receive-PSSession (+)

Register-JobEvent (+)

Remove-TypeData (+)

Rename-Computer (+)

Resume-Job (+)

Save-Help (+)

Show-Command (+)

Show-ControlPanelItem (+)

Suspend-Job (+)

Test-PSSessionConfigurationFile (+)

Unblock-File (+)

Update-Help (+)

About the author: Shay Levy

Shay Levy is a Co-founder and editor of the PowerShell Magazine. He is a multiple-year recipient of the Microsoft MVP award, and a Microsoft Certified Trainer (MCT). Shay often covers PowerShell related topics on his blog and you can also follow him on Twitter at @ShayLevy

Related Posts

%d bloggers like this: