Ubuntu 与 Windows 下 Git 安装方法

Ubuntu

1.打开 shell 界面(终端),输入

sudo apt-get install git-core

按下回车,输入密码,即可完成安装。

2.配置身份,打开shell界面,输入


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


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


配置完成后若想查看配置是否成功,只要使用相同的命令,把最后的名字和邮箱去掉即可。


Windows

1.访问网址 https://git-for-windows.github.io/,点击 Download 按钮进行下载。

2.双击安装包,根据安装步骤进行安装即可。

3.配置身份,打开 Git Bash,输入


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


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


你可能感兴趣的:(Ubuntu 与 Windows 下 Git 安装方法)