-
Notifications
You must be signed in to change notification settings - Fork 8.1k
Closed
Labels
Area-Maintainers-Buildspecific to affecting the buildspecific to affecting the build
Description
Prerequisites
- Write a descriptive title.
- Make sure you are able to repro it on the latest released version
- Search the existing issues.
- Refer to the FAQ.
- Refer to Differences between Windows PowerShell 5.1 and PowerShell.
Steps to reproduce
- install version 7.4.1 of PowerShell 7 (i.e. the previous one)
- go to the folder C:\ProgramData\Microsoft\Windows\Start Menu\Programs\PowerShell\
- edit the
PowerShell 7 (x64)shortcut's advanced properties and set the 'run as administrator' checkbox. Save the shortcut properties. (with elevation confirmation prompt too) - test that PowerShell 7 now requires elevation by default when starting from Start Menu
- make sure pwsh 7 is not running, start an elevated cmd.exe command prompt, run
winget upgrade Microsoft.PowerShell- and update pwsh to version 7.4.2 (https://github.com/PowerShell/PowerShell/releases/download/v7.4.2/PowerShell-7.4.2-win-x64.msi) - now check that shortcut again
Expected behavior
expected behaviour: when upgrading do not mess with existing shortcuts if the executable shortcut path and arguments are correct for the new version, maybe show a confirmation prompt window about replacing them and let the user decide?
alternative expected behaviour, especially when doing silent / unattended upgrades: do not modify already working shortcuts.
Actual behavior
PowerShell installer nuked the old shortcut and created a new one in its place, without the advanced properties that the old shortcut had and did this replacement even if nothing has changed in the executable's path name or arguments.
Error details
(installation issue, not an actual pwsh error)
Environment data
Name Value
---- -----
PSVersion 7.4.2
PSEdition Core
GitCommitId 7.4.2
OS Microsoft Windows 10.0.19045
Platform Win32NT
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1
WSManStackVersion 3.0Visuals
No response
Metadata
Metadata
Assignees
Labels
Area-Maintainers-Buildspecific to affecting the buildspecific to affecting the build