Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 30f803b

Browse filesBrowse files
authored
Merge pull request #28575 from juanis2112/fix-development-workflow
Add branch tracking to development workflow instructions
2 parents 6e69939 + 92bbaa2 commit 30f803b
Copy full SHA for 30f803b

File tree

1 file changed

+17
-12
lines changed
Filter options

1 file changed

+17
-12
lines changed

‎doc/devel/development_workflow.rst

Copy file name to clipboardExpand all lines: doc/devel/development_workflow.rst
+17-12Lines changed: 17 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -79,19 +79,13 @@ default, git will have a link to your fork of the GitHub repo, called
7979

8080
git push origin my-new-feature
8181

82-
In git >= 1.7 you can ensure that the link is correctly set by using the
83-
``--set-upstream`` option::
82+
.. hint::
8483

85-
git push --set-upstream origin my-new-feature
86-
87-
From now on git will know that ``my-new-feature`` is related to the
88-
``my-new-feature`` branch in the GitHub repo.
89-
90-
If you first opened the pull request from your ``main`` branch and then
91-
converted it to a feature branch, you will need to close the original pull
92-
request and open a new pull request from the renamed branch. See
93-
`GitHub: working with branches
94-
<https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches#working-with-branches>`_.
84+
If you first opened the pull request from your ``main`` branch and then
85+
converted it to a feature branch, you will need to close the original pull
86+
request and open a new pull request from the renamed branch. See
87+
`GitHub: working with branches
88+
<https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/proposing-changes-to-your-work-with-pull-requests/about-branches#working-with-branches>`_.
9589

9690
.. _edit-flow:
9791

@@ -167,6 +161,17 @@ You can achieve this by using
167161
git commit -a --amend --no-edit
168162
git push [your-remote-repo] [your-branch] --force-with-lease
169163
164+
.. tip::
165+
Instead of typing your branch name every time, you only need to type the following once to link the remote branch to the local branch::
166+
167+
git push --set-upstream origin my-new-feature
168+
169+
From now on git will know that ``my-new-feature`` is related to the
170+
``my-new-feature`` branch in the GitHub repo. After this, you will be able to
171+
push your changes with::
172+
173+
git push
174+
170175

171176
Manage commit history
172177
=====================

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.