为什么将自己修改内容上传到主分支叫pull request,而不是push request?

为什么将自己修改内容上传到主分支叫pull request,而不是push request?

这里有很多用户对这一问题分享了自己看法,我简单罗列下:

https://stackoverflow.com/questions/21657430/why-is-a-git-pull-request-not-called-a-push-request

1、Picture a big, living tree. The tree is too sturdy for you to push a branch into in, instead you must ask the tree to pull a branch into the trunk, strengthening it.

2、If you have a code change in your repository, and want to move it to a target repository, then:
“Push” is you forcing the changes being present in the target repository (git push).
“Pull” is the target repository grabbing your changes to be present there (git pull from the other repo).
A “pull request” is you requesting the target repository to please grab your changes.
A “push request” would be the target repository requesting you to push your changes.

3、When you send a pull request, you’re asking (requesting) the official repo owner to pull some changes from your own repo. Hence “pull request”.

大概意思就是,push指我们直接将修改内容push到指定分支中,而如果想要自己修改内容被合并到主分支中,就需要pull request,这个拉取请求是对主分支发起的,希望主分支能将自己的修改拉去到主分支中。

版权声明:本文《为什么将自己修改内容上传到主分支叫pull request,而不是push request?》为网站老表爱技术作者「oldwatch」的原创文章,请联系微信:pythonbrief 获取转载权限,或者提问交流。
原文链接:https://python-brief.com/116.html
暂无评论

发送评论 编辑评论


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗㆆ)
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
颜文字
Emoji
小恐龙
花!
上一篇
下一篇