1-1 安装

  1. 先输入yum 看有没有安装yum命令
  2. 有就是下图1 没有就输入下列命令
  3. sudo apt install yum
  4. tips:如果没有yum这个命令,需要先使用上面的命令安装

1-
image.png

  1. yum install git
  2. git --version //可以查看是否安装成功

输入y
image.png
image.png
输出版本号即安装成功

1-2 配置用户名和邮箱

  1. //git config --global user.name "xxx"
  2. git config --global user.name "jiananyao"
  3. //git config --global user.email "xx"
  4. git config --global user.email "843963217@qq.com"
  5. git config --global --list

image.png