安裝
sudo apt install git
配置賬號
git config --global user.email "[email protected]"
git config --global user.name "-----"
首次初始化
git init
添加文件
git add README.md
提交修改
git commit -m "first commit"
設置提交的遠程路徑,後面不用在設置了
git remote add origin
https://github.com/gjq246/pythontest.git
提交到服務器
git push -u origin master
從服務器更新下來
git pull origin master
查看狀態
git status