Skip to content

Commit daee3eb

Browse files
committed
[TASK] Add info on common: "Included in", "commit message"
This improves the docs and adds references for: * How to utilize the "Included in" gerrit feature * How to add a "push message" to gerrit * Move from t3upgrade -> t3coreapi for a link
1 parent 4450825 commit daee3eb

File tree

4 files changed

+59
-1
lines changed

4 files changed

+59
-1
lines changed

Documentation/CheatSheets/Git.rst

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,6 +237,35 @@ Other keywords:
237237
* other lines <= 72 chars
238238
* hyperlinks with > 72 chars are allowed when required (:ref:`<commitmessage-links>`)
239239

240+
Workflow - push with Gerrit message
241+
===================================
242+
243+
Due to the nature of the commit workflow with gerrit, and a commit
244+
always getting amended, you have no individual commit messages for one
245+
Gerrit patch set.
246+
247+
To workaround that, you can add small comments to individual patch sets
248+
pushed to Gerrit like this:
249+
250+
.. code-block:: bash
251+
252+
git push origin HEAD:refs/for/main%m=Fixed_issue_in_JavaScript
253+
254+
Since that notation is a bit bland (no spaces, no linebreaks, no special
255+
characters, it can be helpful to utilize a small Bash script:
256+
257+
.. code-block:: bash
258+
:caption: push_with_message.sh
259+
260+
#!/bin/bash
261+
read -p "Please enter pseudo-commit message: " answer
262+
263+
answer=$(echo "$answer" | tr -c '[:alnum:]' '_')
264+
git push origin HEAD:refs/for/main%m=$answer
265+
266+
Replace "main" with possibly other branches (`13.4`, `12.4`, ...) that
267+
you may want to push to.
268+
240269
Workflow - Undoing / fixing things
241270
==================================
242271

@@ -275,6 +304,21 @@ This is very handy, in case you accidentally created a new commit
275304
instead of adding to an existing commit (with `git commit --amend`). This way,
276305
you can merge the last 2 commits and the commit messages.
277306

307+
.. _cheatsheet-git-included-in:
308+
Information: Where was a patch included?
309+
========================================
310+
311+
Sometimes you see an old gerrit issue that was committed and pushed against
312+
`main`, but wonder in which TYPO3 version it was included. Often, you can
313+
already deduce from a `Releases: main, 12.4` line that it was committed when
314+
`13.4` was `main`. But if you only see `Releases: main` you might begin to look
315+
up the date of a patch and relate it to release dates, or begin to inspect the
316+
git repository manually.
317+
318+
But: Hold on! Just check out the Gerrit interface and on the top right you see
319+
the menu, from where you also cherry-pick a patch or download a patch. There's
320+
a menu entry :guilabel:`Included in` which will reveal all TYPO3 releases (via
321+
GIT tags), a patch was included in.
278322

279323
References
280324
==========

Documentation/CoreMergers/Backport.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,3 +85,10 @@ Edit the commit message to comply to the guidelines again. (e.g. remove the Revi
8585
Push the review back to Gerrit.
8686

8787
On Gerrit the original patch will show the cherry-pick as a related patch.
88+
89+
In which TYPO3 release was a patch merged into?
90+
===============================================
91+
92+
See :ref:`<cheatsheet-git-included-in>` for information on how to use the
93+
:guilabel:`Included in` menu button to see, in which TYPO3 releases a patch
94+
was merged into.

Documentation/HandlingIssues/TicketWorkflow.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ Status
141141

142142
The upside: The patch that has been made may apply to your own instance.
143143
You can always download patches and apply them locally, see
144-
:ref:`Applying Core patches <t3upgrade:applying-core-patches>` for details.
144+
:ref:`Applying Core patches <t3coreapi:applying-core-patches>` for details.
145145

146146
#. Closed
147147

Documentation/Troubleshooting/Index.rst

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -304,3 +304,10 @@ re-create the assets using the following workflow:
304304
305305
You will see the Commit Message again and you can now save it.
306306
When you push this change, it will create a new Patchset - this is expected behavior.
307+
308+
In which TYPO3 release was a patch merged into?
309+
-----------------------------------------------
310+
311+
See :ref:`<cheatsheet-git-included-in>` for information on how to use the
312+
:guilabel:`Included in` menu button to see, in which TYPO3 releases a patch
313+
was merged into.

0 commit comments

Comments
 (0)