Thread:Talk:Git/Workflow/Section I removes

S has added complicated instructions about gerrit/origin.

We are dozens of people to not have any problem. I temporarily removed these confusing instructions, and would like opinion from Git and Gerrit experts.

Here the text:



Using a "gerrit" remote consistently
Before starting with  you should double-check how   refers to repositories. When you clone a repository, by default git gives the remote repository the nickname  (unless you override this with -o gerrit as the sample commands on this page do), thus most git how-tos on the web use "origin". But the  tool prefers to use a remote called. If you're pulling code from gerrit.wikimedia.org then "origin" and "gerrit" are equivalent, yet if you fetch or pull from one but log/show/commit to the other you'll get different results!

Here's how to fix it:


 * Double check the git remotes (nicknames) available:

If it shows something like origin	ssh://username@gerrit.wikimedia.org:29418/mediawiki/core.git (fetch) origin	ssh://username@gerrit.wikimedia.org:29418/mediawiki/core.git (push) then follow these steps.


 * Rename "origin" to "gerrit":

If you already try, the above won't work since you will probably have "gerrit" remote already. So just remove origin:

In order for "git fetch" and "git pull" to show a helpful
 * Change the tracking branch for "git pull":

Your branch is behind 'gerrit/master' by 63 commits, and can be fast-forwarded.

, you need to tell your local branch (for example "master") to track "gerrit/master" instead of "origin/master":

After this you don't need "origin" anymore and you can safely use shortcuts like "git pull" to update your working copy.

Unfortunately you must perform these steps for every project checked out, i.e. core and extensions.

After changes the configuration should look like:
 * Checking if everything is OK:

Should we let this section removed or should I add it again?