PWD displays the current path;
mkdir creating a Local repository directory: $mkdir name
Git init changes the repository directory to a manageable library: $git Init
Git add add file to Staging area: $git Add file name (plus extension)
Git commit save git Add file to library: $git commit-m "notes to add when saving"
Git Status View warehouse current status: $git status
git diff view file differs from previous $git diff file name (plus extension)
git log view commit log in library: $git log
Add--pretty=oneline parameter: $git log--pretty=oneline
Git Reset fallback version:
Fallback to previous version: $git reset--hard head^
Fallback to version with the specified version number: $git Reset--hard version number (just the first few)
Delete the contents of git Add to Staging area: $git reset HEAD file name (plus extension)
Cat View File contents: $cat file name (plus extension)
git diff head see the difference between workspace and repository: $git diff head--file name (plus extension)
git checkout Replace workspace file with version in repository: $git Checkout--file name (plus extension)
RM Delete File:
Delete local file: $rm file name (plus extension)
Delete a repository file: $git RM file name (plus extension)
Create an SSH key:$ ssh-keygen-t rsa-c "Email The first time you use Git"
Git remote add origin adds GitHub address: $git Remote Add Origin address
/* Use the SSH address at a later time to submit without losing the account password, HTTPS to lose */
Git push pushes the local library to GitHub: $git push-u Origin Master
git clone clone Remote Library to Local: $git clone address
Create branch: $git Branch Branch name
Jump to branch: $git Checkout Branch Name
Create and go to New branch: $git Checkout-b Branch Name
View all branches: $git Branch
From branch back to Superior: $git Checkout Superior Name
Merges the specified branch to the current branch: $git merge the branch names to merge
Disable Quick merge: $git merge--no--ff-m "notes information"
View branch Merge Status: Git log--graph--pretty=oneline--abbrev-commit
Delete Branch: $git branch-d Branch Name
Force Delete of unincorporated branch: $git branch-d Branch Name
Freeze Current Branch workspace: $git Stash
Resuming a frozen workspace: $git stash Apply
To delete a restored frozen zone: $git stash drop
Recovering and removing frozen areas: $git stash Pop
Push the specified branch to the remote library: $git push Origin Branch name
Crawl Branch: $git pull
If Git pull hints "No tracking information", then the link relationship between the local branch and the remote branch is not created, with the command git branch--set-upstream branch-name origin/ Branch-name
Create tag: $git tag Signature
View Tags: $git tag
tag for older versions of previous submissions: $git tag Tag name Commit-id
Tagged with description: $git tag name-M "description"
View Description: $git Show label Signature
Delete tag: $git tag-d label Signature
Push all local Tags: $git push origin--tags
Delete Remote Tags: 1. Delete local tags
1. Delete Remote: $git push origin:refs/tags/Sign
The <END> tag appears and cannot be entered: Press Q
End
git command Daquan