@@ -47,7 +47,7 @@ You will only need to do this once.
47
47
Cloning a Forked CPython Repository
48
48
-----------------------------------
49
49
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::
51
51
52
52
git clone git@github.com:<username>/cpython.git
53
53
@@ -58,6 +58,18 @@ It is also recommended to configure an ``upstream`` remote repository::
58
58
59
59
You can also use SSH-based or HTTPS-based URLs.
60
60
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
+
61
73
Listing the Remote Repositories
62
74
-------------------------------
63
75
@@ -71,7 +83,14 @@ and ``upstream`` pointing to the official CPython repository::
71
83
origin git@github.com:<username>/cpython.git (fetch)
72
84
origin git@github.com:<username>/cpython.git (push)
73
85
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.
75
94
76
95
77
96
.. _set-up-name-email :
0 commit comments