Git
Settings
# The default credentials is not to cache at all.
git config --global --unset credential.helper
# The cache mode keeps credentials in memory for a certain period of time.
git config --global credential.helper cache
# The store mode saves the credentials to a plain-text file on disk.
git config --global credential.helper store
# Set user.email
git config --global user.email "[email protected]"
# Set user.name
git config --global user.name "Your Name"
# List all variables set in config file
git config --global --list
Commands
# Clone a repository into a new directory
git clone URI
# List, create, or delete branches
git branch
git branch develop
git branch -d develop
# Switch branches or restore working tree files
git checkout -t origin/develop
git checkout develop
git checkout master
# Join two or more development histories together
git merge --no-ff develop
# Fetch from and integrate with another repository or a local branch
git pull
git pull origin master
git pull origin develop
# Update remote refs along with associated objects
git push
git push origin master
git push origin develop
# Create, list, delete or verify a tag object signed with GPG
git tag
git tag 0.1.0
git push origin 0.1.0
Git branching model
A successful Git branching model