0%

Git

Git

install

1
2
yum install git
git version

git-ssh Config

set the location git config

1
2
3
git config --global user.name "xxx"
git config --global user.email "xxx@xxx"
git config --list

ssh

1
2
3
4
5
6
7
ssh-keygen -t rsa -C "user.email"
cd ~/.ssh/

# Configure the corresponding SSH in GitHub according to the content in id_rsa.pua

# Test
ssh git@github.com

Usage

Git clear workspace and staging area

1
2
3
4
5
6
7
# 1. before add & commit operation
git checkout .
## The above command is invalid for the new operation(file || folder), use clean
git clean -d

# 2. after add operation
git reset .

References

-------------The end of this article, thanks for reading-------------