Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
The PowerShell Core 6.2 release focused on performance improvements, bug fixes, and smaller cmdlet and language enhancements that improve the quality. To see a full list of improvements, check out our detailed changelogs on GitHub.
Experimental Features
Previously, we enabled support for Experimental Features. In the 6.2 release, we have four experimental features to try out. Please provide feedback so we can make improvements and to decide whether the feature is worth promoting to mainstream status.
Use Get-ExperimentalFeature to get a list of available experimental features. You can enable or
disable these features with Enable-ExperimentalFeature and Disable-ExperimentalFeature.
Command Not Found Suggestions
This feature uses fuzzy matching to find suggestions for commands or cmdlets you may have mistyped.
Enable-ExperimentalFeature -Name PSCommandNotFoundSuggestion
Example
In this example, the misspelled cmdlet name is fuzzy matched to several suggestions from most likely to least likely.
Get-Commnd
Get-Commnd : The term 'Get-Commnd' is not recognized as the name of a cmdlet, function, script file,
or operable program. Check the spelling of the name, or if a path was included, verify that the path
is correct and try again.
At line:1 char:1
+ Get-Commnd
+ ~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (Get-Commnd:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
Suggestion [4,General]: The most similar commands are: Get-Command, Get-Content, Get-Job, Get-Module,
Get-Event, Get-Host, Get-Member, Get-Item, Set-Content.
Implicit Remoting Batching
When using implicit remoting
in a pipeline, PowerShell treats each command in the pipeline independently. Objects are repeatedly
serialized and de-serialized between the client and remote system over the execution of the
pipeline.
With this feature, PowerShell analyzes the pipeline to determine if the command is safe to run and
it exists on the target system. When true, PowerShell executes the entire pipeline remotely and only
serializes and de-serializes the results back to the client.
Enable-ExperimentalFeature -Name PSImplicitRemotingBatching
A real-world test of Get-Process | Sort-Object over localhost decreases from 10-15 seconds to
20-30 milliseconds. The feature only needs to be enabled on the client. No changes are required
on the server.
Temp Drive
Enable-ExperimentalFeature -Name PSTempDrive
If you're using PowerShell Core on different operating systems, you'll discover that the environment
variable for finding the temporary directory is different on Windows, macOS, and Linux! With this
feature, you get a PSDrive called Temp: that is automatically mapped to the temporary folder
for the operating system you are using.
Example
PS> "Hello World!" > Temp:/hello.txt
PS> Get-Content Temp:/hello.txt
Hello World!
Be aware that native file commands (like ls on Linux) are not aware of PSDrives and won't see this
Temp: drive.
Abbreviation Expansion
PowerShell cmdlets are expected to have descriptive nouns. This results in long names that are more difficult to type. This feature allows you to just type the uppercase characters of the cmdlet and use tab-completion to find a match.
Enable-ExperimentalFeature -Name PSUseAbbreviationExpansion
Example
PS> i-arsavsf
If you hit tab, and have the Azure PowerShell Az module installed, it will autocomplete to:
PS> Import-AzRecoveryServicesAsrVaultSettingsFile
Note
This feature is intended to be used interactively. Abbreviated forms of cmdlets can't be executed. This feature is not a replacement for aliases.
Breaking Changes
- Fix
-NoEnumeratebehavior inWrite-Outputto be consistent with Windows PowerShell. (#9069) - Make
Join-String -InputObject 1,2,3result equal to1,2,3 | Join-Stringresult (#8611) (Thanks @sethvs!) - Add
-StabletoSort-Objectand related tests (#7862) (Thanks @KirkMunro!) - Improve
Start-Sleepcmdlet to accept fractional seconds (#8537) (Thanks @Prototyyppi!) - Change hashtable to use OrdinalIgnoreCase to be
case-insensitivein all Cultures (#8566) - Fix LiteralPath in
Import-Csvto bind toGet-ChildItemoutput (#8277) (Thanks @iSazonov!) - No longer skips a column without name if double quote delimiter is used in
Import-Csv(#7899) (Thanks @Topping!) Get-ExperimentalFeatureno longer has-ListAvailableswitch (#8318)- Debug parameter now sets
$DebugPreferenceto Continue instead of Inquire (#8195) (Thanks @KirkMunro!) - Honor
-OutputFormatif specified in non-interactive, redirected, encoded command used with pwsh (#8115) - Load assembly from module base path before trying to load from the GAC (#8073)
- Remove tilde from Linux preview packages (#8244)
- Move processing of
-WorkingDirectorybefore processing of profiles (#8079) - Do not add
PATHEXTenvironment variable on Unix (#7697) (Thanks @iSazonov!)
Known Issues
- Remoting on Windows IOT ARM platforms has an issue loading modules. See (#8053)
General Updates and Fixes
- Enable case-insensitive tab completion for files and folders on case-sensitive filesystem (#8128)
- Make PSVersionInfo.PSVersion and PSVersionInfo.PSEdition public (#8054) (Thanks @KirkMunro!)
- Add Type Inference for
$_/$PSItemincatch{ }blocks (#8020) (Thanks @vexx32!) - Fix static method invocation type inference (#8018) (Thanks @SeeminglyScience!)
- Create inferred types for
Select-Object,Group-Object, PSObject and Hashtable (#7231) (Thanks @powercode!) - Support calling method with
ByRef-liketype parameters (#7721) - Handle the case where the Windows PowerShell module path is already in the environment's PSModulePath (#7727)
- Enable
SecureStringcmdlets for non-Windows by storing the plain text (#9199) - Improve error message on non-Windows when importing clixml with securestring (#7997)
- Adding parameter ReplyTo to
Send-MailMessage(#8727) (Thanks @replicaJunction!) - Add Obsolete message to
Send-MailMessage(#9178) - Fix
Restart-Computerto work onlocalhostwhen WinRM is not present (#9160) - Make
Start-Jobthrow terminating error when PowerShell is being hosted (#9128) - Add C# style type accelerators and suffixes for ushort, uint, ulong, and short literals (#7813) (Thanks @vexx32!)
- Added new suffixes for numeric literals - see about_Numeric_Literals (#7901) (Thanks @vexx32!)
- Correctly Report impact level when SupportsShouldProcess is not set to 'true' (#8209) (Thanks @vexx32!)
- Fix Request Charset Issues in Web Cmdlets (#8742) (Thanks @markekraus!)
- Fix Expect
100-continueissue with Web Cmdlets (#8679) (Thanks @markekraus!) - Fix file blocking issue with web cmdlets (#7676) (Thanks @Claustn!)
- Fix code page parsing issue in
Invoke-RestMethod(#8694) (Thanks @markekraus!) - Refactor
ConvertTo-Jsonto expose JsonObject.ConvertToJson as a public API (#8682) - Add configurable maximum depth in
ConvertFrom-Jsonwith -Depth (#8199) (Thanks @louistio!) - Add EscapeHandling parameter in
ConvertTo-Jsoncmdlet (#7775) (Thanks @iSazonov!) - Add
-CustomPipeNameto pwsh andEnter-PSHostProcess(#8889) - Enable creating relative symbolic links on Windows with
New-Item(#8783) - Allow Windows users in developer mode to create symlinks without elevation (#8534)
- Enable
Write-Informationto accept$null(#8774) - Fix
Get-Helpfor advanced functions with MAML help content (#8353) - Fix
Get-HelpPSTypeName issue with -Parameter when only one parameter is declared (#8754) (Thanks @pougetat!) - Token calculation fix for
Get-Helpexecuted on ScriptBlock for comment help. (#8238) (Thanks @hubuk!) - Change
Get-Helpcmdlet -Parameter parameter so it accepts string arrays (#8454) (Thanks @sethvs!) - Resolve PAGER if its path contains spaces (#8571) (Thanks @pougetat!)
- Add prompt to the use of
lessin the function 'help' to instruct user how to quit (#7998) - Add support enum and char types in
Format-Hexcmdlet (#8191) (Thanks @iSazonov!) - Remove ShouldProcess from
Format-Hex(#8178) - Add new Offset and Count parameters to
Format-Hexand refactor the cmdlet (#7877) (Thanks @iSazonov!) - Allow 'name' as an alias key for 'label' in
ConvertTo-Html, allow the 'width' entry to be an integer (#8426) (Thanks @mklement0!) - Make scriptblock based calculated properties work again in
ConvertTo-Html(#8427) (Thanks @mklement0!) - Add cmdlet
Join-Stringfor creating text from pipeline input (#7660) (Thanks @powercode!) - Fix
Join-Stringcmdlet FormatString parameter logic (#8449) (Thanks @sethvs!) - Change
Clear-Hostback to using$RAWUIand clear to work over remoting (#8609) - Change
Clear-Hostto simply called[console]::clearand remove clear alias from Unix (#8603) - Fix LiteralPath in
Import-Csvto bind toGet-ChildItemoutput (#8277) (Thanks @iSazonov!) - help function shouldn't use pager for AliasHelpInfo (#8552)
- Add
-UseMinimalHeadertoStart-Transcriptto minimize transcript header (#8402) (Thanks @lukexjeremy!) - Add
Enable-ExperimentalFeatureandDisable-ExperimentalFeaturecmdlets (#8318) - Expose all cmdlets from PSDiagnostics if logman.exe is available (#8366)
- Remove Persist parameter from
New-PSDriveonnon-Windowsplatform (#8291) (Thanks @lukexjeremy!) - Add support for
cd +(#7206) (Thanks @bergmeister!) - Enable
Set-Location -LiteralPathto work with folders named - and + (#8089) Test-Pathreturns$falsewhen given an empty or$nullpath value (#8080) (Thanks @vexx32!)- Allow dynamic parameter to be returned even if path does not match any provider (#7957)
- Support
Get-PSHostProcessInfoandEnter-PSHostProcesson Unix platforms (#8232) - Reduce allocations in
Get-Contentcmdlet (#8103) (Thanks @iSazonov!) - Enable
Add-Contentto share read access with other tools while writing content (#8091) Get/Add-Contentthrows improved error when targeting a container (#7823) (Thanks @kvprasoon!)- Add
-Name,-NoUserOverridesand-ListAvailableparameters toGet-Culturecmdlet (#7702) (Thanks @iSazonov!) - Add unified attribute for completion for Encoding parameter. (#7732) (Thanks @ThreeFive-O!)
- Allow numeric Ids and name of registered code pages in Encoding parameters (#7636) (Thanks @iSazonov!)
- Fix
Rename-Item -Pathwith wildcard char (#7398) (Thanks @kwkam!) - When using
Start-Transcriptand file exists, empty file rather than deleting (#8131) (Thanks @paalbra!) - Make
Add-Typeopen source files with FileAccess.Read and FileShare.Read explicitly (#7915) (Thanks @IISResetMe!) - Fix
Enter-PSSession -ContainerIdfor the latest Windows (#7883) - Ensure NestedModules property gets populated by
Test-ModuleManifest(#7859) - Add
%Fcase toGet-Date-UFormat (#7630) (Thanks @britishben!) - Fix
Set-Service -Status Stoppedto stop services with dependencies (#5525) (Thanks @zhenggu!)