为什么 git 'pull request' 不称为 'push request'? [英] Why is a git 'pull request' not called a 'push request'?

查看:34
本文介绍了为什么 git 'pull request' 不称为 'push request'?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

用于将分支与官方存储库合并的术语是拉取请求".这令人困惑,因为我似乎要求将我的更改推送到官方存储库.

The terminology used to merge a branch with an official repository is a 'pull request'. This is confusing, as it appears that I am requesting to push my changes to the official repository.

为什么它被称为拉取请求而不是推送请求?

Why is it called a pull request and not a push request?

推荐答案

如果您的存储库中有代码更改,并希望将其移动到目标存储库,则:

If you have a code change in your repository, and want to move it to a target repository, then:

  • 推送"是您强制目标存储库中存在的更改(git push).
  • Pull"是目标存储库,将您的更改抓取到那里(git pull 来自另一个存储库).
  • "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.

这篇关于为什么 git 'pull request' 不称为 'push request'?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆