Git 在 Windows 11 Powershell 中无法工作(选择一个应用程序打开“git”)

问题描述 投票:0回答:1

我已经下载了 Windows 版的 git,
git 版本 2.44.0.windows.1

在 Windows cmd & Git Bash & Powershell x86 中运行良好

但是,在 Windows Powershell 中运行时,我收到“选择要打开的应用程序”,

我的环境变量(系统)也设置为

C:\Program Files\Git\bin\
C:\Program Files\Git\cmd\
git powershell
1个回答
0
投票

运行命令

Get-Command -Name git

似乎它在 Windows Powershell 中指向了错误的源。 当更改环境优先级以允许它首先运行或删除其他 git 时解决了问题

© www.soinside.com 2019 - 2024. All rights reserved.