<spanid="set-up-fork"></span><h1>Set up your fork<aclass="headerlink" href="#set-up-your-fork" title="Permalink to this headline">¶</a></h1>
<p>First you follow the instructions for <aclass="reference internal" href="forking_hell.html#forking"><em>Making your own copy (fork) of matplotlib</em></a>.</p>
<divclass="section" id="overview">
<h2>Overview<aclass="headerlink" href="#overview" title="Permalink to this headline">¶</a></h2>
<li><pclass="first">Investigate. Change directory to your new repo: <ttclass="docutils literal"><spanclass="pre">cd</span><spanclass="pre">matplotlib</span></tt>. Then
<ttclass="docutils literal"><spanclass="pre">git</span><spanclass="pre">branch</span><spanclass="pre">-a</span></tt> to show you all branches. You’ll get something
like:</p>
<divclass="highlight-python"><pre>* master
remotes/origin/master</pre>
</div>
<p>This tells you that you are currently on the <ttclass="docutils literal"><spanclass="pre">master</span></tt> branch, and
that you also have a <ttclass="docutils literal"><spanclass="pre">remote</span></tt> connection to <ttclass="docutils literal"><spanclass="pre">origin/master</span></tt>.
What remote repository is <ttclass="docutils literal"><spanclass="pre">remote/origin</span></tt>? Try <ttclass="docutils literal"><spanclass="pre">git</span><spanclass="pre">remote</span><spanclass="pre">-v</span></tt> to
see the URLs for the remote. They will point to your <aclass="reference external" href="http://github.com">github</a> fork.</p>
<p>Now you want to connect to the upstream <aclass="reference external" href="http://github.com/matplotlib/matplotlib">matplotlib github</a> repository, so
<spanid="linking-to-upstream"></span><h3>Linking your repository to the upstream repo<aclass="headerlink" href="#linking-your-repository-to-the-upstream-repo" title="Permalink to this headline">¶</a></h3>
<p><ttclass="docutils literal"><spanclass="pre">upstream</span></tt> here is just the arbitrary name we’re using to refer to the
main <aclass="reference external" href="http://matplotlib.org">matplotlib</a> repository at <aclass="reference external" href="http://github.com/matplotlib/matplotlib">matplotlib github</a>.</p>
<p>Note that we’ve used <ttclass="docutils literal"><spanclass="pre">git://</span></tt> for the URL rather than <ttclass="docutils literal"><spanclass="pre">git@</span></tt>. The
<ttclass="docutils literal"><spanclass="pre">git://</span></tt> URL is read only. This means we that we can’t accidentally
(or deliberately) write to the upstream repo, and we are only going to
use it to merge into our own code.</p>
<p>Note this command needs to be run on every clone of the repository
that you make. It is not tracked in your personal repository on
<p>Just for your own satisfaction, show yourself that you now have a new
‘remote’, with <ttclass="docutils literal"><spanclass="pre">git</span><spanclass="pre">remote</span><spanclass="pre">-v</span><spanclass="pre">show</span></tt>, giving you something like:</p>