首先确保你的本地git工作目录下已经增加了远程分支了 使用 git remote -v 查看。 如果没有则先使用 git remote add 命令添加一个(假设名为origin,分支为master)。 如果已经有了,则使用 git push origin master命令提交当前工作目录下的分支