11<!-- DO NOT EDIT THIS FILE!
22
3- It was automatically created by task/scripts/github-documentation-update at Tue Apr 8 13:30:36 CEST 2025.
3+ It was automatically created at 2025-04-09T11:40:57+02:00
4+ by task/scripts/github-documentation-update
5+ based on /app/task/scripts/../templates/github-actions-templates.md
46-->
57# Github Actions templates
68
@@ -22,6 +24,8 @@ to match the new templates.
2224
2325## Templates
2426
27+ The current list of templates is shown in the following sections.
28+
2529---
2630
2731[ github/workflows/changelog.yaml] ( github/workflows/changelog.yaml )
@@ -59,7 +63,34 @@ Validates composer.json and checks that it's normalized.
5963
6064[ github/workflows/drupal/php.yaml] ( github/workflows/drupal/php.yaml )
6165
62- Drupal PHP
66+ ### Drupal PHP
67+
68+ Checks that PHP code adheres to the [ Drupal coding
69+ standards] ( https://www.drupal.org/docs/develop/standards ) .
70+
71+ #### Assumptions
72+
73+ 1 . A docker compose service named ` phpfpm ` can be run and ` composer ` can be
74+ run inside the ` phpfpm ` service.
75+ 2 . [ drupal/coder] ( https://www.drupal.org/project/coder ) is a dev requirement
76+ in ` composer.json ` :
77+
78+ ``` shell
79+ docker compose run --rm phpfpm composer require --dev drupal/coder
80+ ```
81+
82+ Clean up and check code by running
83+
84+ ``` shell
85+ docker compose run --rm phpfpm vendor/bin/phpcbf
86+ docker compose run --rm phpfpm vendor/bin/phpcs
87+ ```
88+
89+ > [ !NOTE]
90+ > The template adds ` .phpcs.xml.dist ` as [ a configuration file for
91+ > PHP_CodeSniffer] ( https://github.com/squizlabs/PHP_CodeSniffer/wiki/Advanced-Usage#using-a-default-configuration-file )
92+ > and this makes it possible to override the actual configuration used in a
93+ > project by adding a more important configuration file, e.g. ` .phpcs.xml ` .
6394
6495---
6596
@@ -92,8 +123,10 @@ JavaScript (and TypeScript)
92123Uses [ itkdev/markdownlint] ( https://hub.docker.com/r/itkdev/markdownlint ) to
93124link all Markdown files (` **/*.md ` ) in the project.
94125
95- [ markdownlint-cli configuration ### files] ( https://github.com/igorshubovych/markdownlint-cli?tab=readme-ov-file#configuration ) ,
96- ` .markdownlint.jsonc ` and ` .markdownlintignore ` control what is actually linted and how.
126+ [ markdownlint-cli configuration
127+ files] ( https://github.com/igorshubovych/markdownlint-cli?tab=readme-ov-file#configuration ) ,
128+ ` .markdownlint.jsonc ` and ` .markdownlintignore ` , control what is actually
129+ linted and how.
97130
98131---
99132
@@ -105,7 +138,7 @@ Styles (CSS and SCSS)
105138
106139[ github/workflows/symfony/php.yaml] ( github/workflows/symfony/php.yaml )
107140
108- Symfony PHP
141+ ### Symfony PHP
109142
110143---
111144
@@ -131,3 +164,27 @@ Validates Twig files
131164 in the root of the project defines which files to check and rules to use.
132165
133166---
167+
168+ ## Updating template documentation
169+
170+ To update this document, run
171+
172+ ``` shell
173+ task github-actions:documentation:update
174+ ```
175+
176+ ### GitHub Actions workflow documentation convention
177+
178+ Each workflow file must contain a single documentation block with lines starting with ` ### ` , e.g.
179+
180+ ``` markdown
181+ ### ### The title
182+ ###
183+ ### This template …
184+ ###
185+ ### See … for details.
186+ ```
187+
188+ > [ !IMPORTANT]
189+ > All lines in the documentation block must start with ` ### ` and the documentation block consists of all consecutive
190+ > lines starting with ` ### ` .
0 commit comments