git basic configuration
Install git yum - the y-install git git Global git config - , Ltd. Free Join user.name " LSC " # configure git users use git config - , Ltd. Free Join user.email " [email protected] " # configure git mailbox git config - , Ltd. Free Join color.ui to true # syntax highlighting git config --list global View #
Git common operations
git commit code
# Submitting files to the staging area git add. # Add all the changes to the file git add test.py # Adds the specified file # to view the status git Status # submitted to the local code library git the commit -m " commit " # the Push to remote code library the Push git - U Origin Master # update the code, you must project directory in git git pull
git clone designated tag
clone --depth = Git 1 --branch = specified address tag git @ - depth depth depth specifies the cloning of 1 means that only the most recent cloning the commit. --branch pulling specified tag