vs 开发者powershell安装git

在 VS 开发者 PowerShell 中安装 Git 的方法是:

  1. 打开 VS 开发者 PowerShell

  2. 运行以下命令安装 chocolatey(一个 Windows 包管理器):

Set-ExecutionPolicy Bypass -Scope Process -Force; System.Net.ServicePointManager::SecurityProtocol = System.Net.ServicePointManager::SecurityProtocol -bor 3072; iex ((New-Object System.Net.WebClient).DownloadString('https://community.chocolatey.org/install.ps1'))

  1. 使用 chocolatey 安装 git:

choco install git -y

  1. 等待安装完成后,验证是否安装成功:

git --version

如果正确打印出 git 版本,则表示已经成功安装。

  1. 最后设置全局的用户名称和邮箱:

git config --global user.name "your name"

git config --global user.email "your@email.com"

这样就在 VS 开发者 PowerShell 中安装好了 git。后续就可以使用 git 相关命令了。

let me know if you have any other questions!

相关推荐
GoodStudyAndDayDayUp10 小时前
GXW-Git规范
git
weixin_307779131 天前
Git中获取一个目录下所有文件的最后修改人的邮箱
开发语言·git·算法
ynchyong1 天前
Git 急救指南:手滑 add / commit 错了,怎么优雅地撤回
git·手滑
Zucker n2 天前
Git 常用命令速查(自用笔记)
git
雪碧聊技术2 天前
Git实战:在Idea中,如何只将分支 A 某次 Commit记录的单个文件同步到分支 B?一文详解|保姆教程
git·文件对比,一键应用
Mortalbreeze2 天前
Git 基础篇(三):分支管理
git
Zucker n2 天前
安装 Git for Windows(自用笔记)
笔记·git
棒子胡豆3 天前
Git总结
git
`流年づ5 天前
联邦学习-安全聚合
git·安全·github
喜欢吃燃面5 天前
Git 原理与使用(三):标签、多人协作与 Git Flow 落地
大数据·git·elasticsearch