You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多
文档控制台
免费开始使用

升级PowerShell至7版本失败求助

升级PowerShell至7版本失败求助

各位好,我最近尝试把PowerShell从5.1版本升级到7,大家都推荐用这条命令:
winget install --id Microsoft.Powershell --source winget

但不管是我家里的Win11电脑,还是公司的Win11电脑,执行这个命令都没成功。

先给大家看看我当前PowerShell的版本信息:

Name Value

PSVersion 5.1.22621.2506
PSEdition Desktop
PSCompatibleVersions {1.0, 2.0, 3.0, 4.0...}
BuildVersion 10.0.22621.2506
CLRVersion 4.0.30319.42000
WSManStackVersion 3.0
PSRemotingProtocolVersion 2.3
SerializationVersion 1.1.0.1

从系统的PATH变量能查到,当前PowerShell的安装路径是:C:\Windows\System32\WindowsPowerShell\v1.0\

执行winget命令时,命令行返回的反馈是:

Found an existing package already installed. Trying to upgrade the
installed package... A newer version wa...

备注:内容来源于stack exchange,提问作者onefootswill

火山引擎 最新活动