What does Git Remote and Origin mean

What does "origin" mean in "Git Push Origin Master"?

When i run:

... what does that mean in this context?


is the default name of the remote Git repository you cloned from. Take a look at your sources and see how git it knows.

git has a concept of "remotes" - these are simple nicknames for a repository so you don't have to use the full URL every time you want to point to a different repository.

is just a remote control like any other, but you see it a lot because the first time you clone a repository, it defaults to a remote control that is invoked to point to the url you cloned from.

When you do this, you will be shown all of the remotes that you have set up in your local repository, as well as the URLs they point to. (You will see that it is a little more complex than mentioned above as a remote control can point to a different url to press and get, but you probably don't have to worry about that. :))

The origin is the place where you put the code originally have received.

That would be help


n Git, "origin" is an abbreviation for the remote repository from which a project was originally cloned. More specifically, it is used in place of the original repository's URL - making referencing a lot easier.

Note that the origin is by no means a "magic" name, just a standard convention. While it makes sense to leave this convention untouched, you can rename it perfectly without losing functionality.

In the following example, the URL parameter to the clone command becomes the "source" of the cloned local repository:

Git clone https://github.com/gittower/git-crash-course.git

origin is created remotely by Git itself if you reference the url from which you created the clone for the first clone of the repo. e.g. origin [email protected]: / PROJECT_U

"Origin" is the name of the remote repository where you want to publish your commits. By default, the default remote repository is named "Origin", but you can work with multiple remotes (with different names) at the same time.

We use cookies and other tracking technologies to improve your browsing experience on our website, to show you personalized content and targeted ads, to analyze our website traffic, and to understand where our visitors are coming from.

By continuing, you consent to our use of cookies and other tracking technologies and affirm you're at least 16 years old or have consent from a parent or guardian.

You can read details in our Cookie policy and Privacy policy.