push

2023-07-13

push 是 [[Git]] 推送命令,用于将本地仓库的提交推送到远程仓库。

语法

Terminal window
git push <remote> <branch>
  • remote:远程仓库名称;
  • branch:分支名称;

使用

推送指定分支:

Terminal window
git push origin master

推送所有分支:

Terminal window
git push origin --all

推送指定标签:

Terminal window
git push origin v0.0.42

推送所有标签:

Terminal window
git push origin --tags