The typical scenario in git workflow:
graph LR;
init --> add --> commit --> push
git init
initialize the current dictionary into a git repository.git add [filename]
add make given files under version tracking. The added files will be at stage.git commit
submit the modifications in stage.git push
push the current repository into remote server. You need to configure the corresponding git repository on the server before git push
.Use git status
to query the current status of git repository. There are several possible states:
Clean. The message looks like
On branch master
Your branch is up to date with 'origin/master'.
nothing to commit, working tree clean
There is change in working space but has not been staged.
All the change in working space has been staged.