change the value $ShellId to powershell rather than Microsoft.PowerShell
PS C:\> $PSVersionTable
Name Value
---- -----
PSVersion 7.0.0-rc.1
PSEdition Core
GitCommitId 7.0.0-rc.1
OS Microsoft Windows 6.3.9600
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0鈥
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0
PS C:\> $ShellId
Microsoft.PowerShell
PS C:\>
This would be breaking change, from what I can tell, because $ShellID is used to derive configuration paths / settings from, notably the (current-host) $PROFILE path(s). (The distinction between the editions is in the parent directory name).
Also, PS Core is still _Microsoft_ PowerShell, just not _Windows_ PowerShell anymore.
To distinguish between the editions you have $PSVersionTable.Edition and $IsCoreCLR.
This issue has been marked as answered and has not had any activity for 1 day. It has been closed for housekeeping purposes.
Most helpful comment
This would be breaking change, from what I can tell, because
$ShellIDis used to derive configuration paths / settings from, notably the (current-host)$PROFILEpath(s). (The distinction between the editions is in the parent directory name).Also, PS Core is still _Microsoft_ PowerShell, just not _Windows_ PowerShell anymore.
To distinguish between the editions you have
$PSVersionTable.Editionand$IsCoreCLR.