# 先拉取远端代码 $ git pull origin master --allow-unrelated-histories # 然后再推送本地代码到远端 $ git push -u origin master