DWQA QuestionsCategory: Development Tool`Is' pull request 'on GitHub' related to 'pull' of 'git'?
Chener asked 4 weeks ago

Previous useSAEIt’s time to learnsvnLater, it was found thatGitAdvanced, and then the registration will not be used for a long timeGithubTake out the account number and make trouble. The result is rightpull requestIt’s very confusing.
Update:
[last second] pull, isn’t it? It feels like push request is the right way to think.
[next second] Oh! For the author, pull…
That is, they don’t match at all. One isCLIOne isGithubSomething conceptual.

2 Answers
Best Answer
n͛i͛g͛h͛t͛i͛r͛e͛ answered 4 weeks ago

Let me be more clear. The previous answers and discussions are specious, and they do not point to the truth.
On GitHubpull requestandgit pullIt’s not entirely irrelevant, but the closest thing to it is another commandgit request-pull
Let’s start with the conceptual explanation. Maybe most people (including the subject) will understand thispull request

I, submit a request to integrate my changes into upstream

In this way, the feeling should bepush requestMost appropriate, because this action is completely my initiative!
However, this understanding ignores a premise:Do you have permission to push to upstream?In other words, can you write upstream directly?
There are two cases (corresponding to two git based workflows):

  1. With authority – then you don’t have tofork & pull requestSince the author gives you permission, you can just clone it and operate it as your repo. Why bother?
  2. No authority – since no authority, whypush requestOne said?

In the final analysis, the cause of this misunderstanding is not completely clearpull requestHow workflow works. aboutpull requestThe correct description of the action should be as follows:

I, initiate a request (in the case of GitHub, an HTTP request calls the corresponding API, which is then executed by GitHub at the back endgit request-pull, see later), this request(request in HTTP request)It is a request.(request in pull request)The author of the upper reaches(pull in pull request)Changes from my fork.

This is the correct understanding.
Finally, let’s talk about itgit request-pull。 When you makepull requestAt the time of request, what is actually carried out isgit request-pullThis subcommand. The signature of this subcommand is as follows:

bash$ git request-pull <start> <url> [<end>]

This command generates a summary that contains the change record (in commit units) and the address used to grab the changes. Output the fixed format plain text to stdout, you can redirect and write code for subsequent processing. That’s how GitHub analyzes each onepull requestSo you can see the corresponding commit, time, author and so on.
The upstream author is receivingpull requestLater, if you choose to accept, GitHub callsgit pullTo specify the address (included ingit request-pullIn the generated message) pull the code. The upstream author naturally has the permission to write the upstream repo, so a complete process can be realized.
It is recommended to read git’s official manual, especially this chapter:Distributed git – contribute to the projectAfter reading it, I’m sure you’ll benefit a lot.

jamlee answered 4 weeks ago

Open library, right? You can pull your changes to this library, and then the author of this library can see your request and decide whether to merge it with his original library.

jamlee replied 4 weeks ago

Yes. It’s probably understandable