![]() The string origin is the default name of the (singular) remote that git clone puts in automatically, when you clone from some other ("origin"-al) Git repository. You rarely (if ever) refer to the 'local' repo explicitly since your operations are performed in the context of a repo.Ī remote is just a word: a name to use to identify some other Git repository somewhere. If there is no master branch in the remote then one will be created.įull details of the push command and the flags, options etc are of course in the docs. If you find that origin does not really work for you then you can change it.Īs for your interpretations of the push statement, your first is the closest to being correct but the push command as written will push the local master branch to the master branch on the remote identified by the (locally configured) name origin. :)Īnd as Jan points out in the comments, the name associated with each remote is intended for your convenience. origin is simply (and literally) the first among those equals (for a cloned repo). Remember that git is a peer-to-peer, distributed system, not one with any built-in notion of client/server, master/slave, parent/child relationships (though these might be imposed upon it by a user in a particular scenario).Īll remotes are equal. It might equally have been called source or remote1 or just remote. ![]() In git lingo origin is just the default name for a remote from which a repo was originally cloned.
0 Comments
Leave a Reply. |