Push the code to coding, use the following three commands when submitting for the first time,
# git add .
# git commit -m"init project"
# git push
What I want to ask is, every time I change the code in the future, will I execute these three commands when I want to submit it?
Generally yes, if you delete a file it should be git add -A, I can’t remember clearly
add can be merged into commit -am "xxx" without new files.
In addition, it is best to git status before each commit.
Yes, but if you want to delete a file you still need
git rm
一下。还有添加.gitignore
的话得另外add
。建议时常git status
.Actually, you’ll know once you try it, don’t be afraid
Yes. But don't use specific filenames like
git add .
,使用git add filepath/filename.py
.If you only modify the file, the first two can be merged into one git commit -a -m ""