Skip to content

Commit e1ff69d

Browse files
author
AndoniLarz
committed
[UPDATE] Add documentation for rebasing when contributing to the docs
1 parent 37f420a commit e1ff69d

File tree

1 file changed

+30
-1
lines changed

1 file changed

+30
-1
lines changed

contributing/documentation/overview.rst

Lines changed: 30 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,9 +136,38 @@ even remove any content and do your best to comply with the
136136
137137
**Step 6.** **Push** the changes to your forked repository:
138138

139+
Rebase your branch
140+
~~~~~~~~~~~~~~~~~~~~~~~~
141+
142+
Before submitting your PR, update your branch (needed if it takes you a
143+
while to finish your changes):
144+
145+
.. code-block:: terminal
146+
147+
$ git checkout 6.x
148+
$ git fetch upstream
149+
$ git merge upstream/6.x
150+
$ git checkout improve_install_article
151+
$ git rebase 6.x
152+
153+
.. tip::
154+
155+
Replace ``6.x`` with the branch you selected previously (e.g. ``5.4``).
156+
157+
When doing the ``rebase`` command, you might have to fix merge conflicts.
158+
``git status`` will show you the *unmerged* files. Resolve all the conflicts,
159+
then continue the rebase:
160+
161+
.. code-block:: terminal
162+
163+
$ git add ... # add resolved files
164+
$ git rebase --continue
165+
166+
Make sure that the docs still build correctly and push your branch remotely:
167+
139168
.. code-block:: terminal
140169
141-
$ git push origin improve_install_article
170+
$ git push --force origin improve_install_article
142171
143172
The ``origin`` value is the name of the Git remote that corresponds to your
144173
forked repository and ``improve_install_article`` is the name of the branch you

0 commit comments

Comments
 (0)