@@ -47,7 +47,7 @@ You will only need to do this once.
4747Cloning a Forked CPython Repository
4848-----------------------------------
4949
50- You will only need to do this once. From your command line::
50+ You will only need to do this once per machine . From your command line::
5151
5252 git clone git@github.com:<username>/cpython.git
5353
@@ -58,6 +58,18 @@ It is also recommended to configure an ``upstream`` remote repository::
5858
5959You can also use SSH-based or HTTPS-based URLs.
6060
61+ Configure the Remotes
62+ ---------------------
63+
64+ Configure ``git `` to pull ``main `` from the ``upstream `` remote::
65+
66+ git config --local branch.main.remote upstream
67+
68+ Since one should never attempt to push to ``upstream ``, configure
69+ ``git `` to push always to ``origin ``::
70+
71+ git remote set-url --push upstream git@github.com:<username>/cpython.git
72+
6173Listing the Remote Repositories
6274-------------------------------
6375
@@ -71,7 +83,14 @@ and ``upstream`` pointing to the official CPython repository::
7183 origin git@github.com:<username>/cpython.git (fetch)
7284 origin git@github.com:<username>/cpython.git (push)
7385 upstream git@github.com:python/cpython.git (fetch)
74- upstream git@github.com:python/cpython.git (push)
86+ upstream git@github.com:<username>/cpython.git (push)
87+
88+ To verify the upstream for ``main ``::
89+
90+ git config branch.main.remote
91+
92+ It should emit ``upstream ``, indicating to track/pull changes for ``main `` from the
93+ ``upstream `` remote.
7594
7695
7796.. _set-up-name-email :
0 commit comments