weskitt
发布于 2025-05-15 / 4 阅读
0

在 Windows 10/11 上更新 PowerShell

使用Winget命令:

Winget 是 Windows 10 中引入的命令行包管理器,它允许您从集中存储库下载并安装软件包。要使用 Winget 命令行工具安装或更新 PowerShell Core 7,请按照以下步骤操作:

  1. 使用管理权限打开 PowerShell 窗口。

  2. 要搜索可用的 PowerShell 版本,请运行以下命令:winget search Microsoft.Powershell

  1. 要安装所需的 PowerShell Core 版本,请使用以下命令:winget install --id Microsoft.PowerShell

这将下载并安装最新的稳定 PowerShell Core 版本。