Skip to content

Commit 05d37ce

Browse files
authored
Merge pull request #18 from move-elevator/content-blocks
feat: add ci linting template for content blocks
2 parents b15de9e + 209c1ad commit 05d37ce

2 files changed

Lines changed: 26 additions & 3 deletions

File tree

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Use `include` to reference template files:
1919
include:
2020
- 'https://raw.githubusercontent.com/move-elevator/gitlab-ci-templates/main/.base.yml'
2121
- 'https://raw.githubusercontent.com/move-elevator/gitlab-ci-templates/main/build/build-php.yml'
22-
- ...
22+
- ...
2323
```
2424
2525
Extend and override configuration variables, see [.base.yaml](.base.yaml) for predefined variables.
@@ -49,6 +49,7 @@ Analyze code quality and static analysis.
4949

5050
Includes:
5151
- `analyze/analyze-composer-lint.yaml`
52+
- `analyze/analyze-content-blocks-lint.yaml`
5253
- `analyze/analyze-editorconfig.yaml`
5354
- `analyze/analyze-js-lint.yaml`
5455
- `analyze/analyze-php-cs-fixer.yaml`
@@ -64,7 +65,7 @@ Includes:
6465

6566
### Feature Branch Deployment
6667

67-
Deploy feature branches to a dedicated environment.
68+
Deploy feature branches to a dedicated environment.
6869

6970
The deployment uses [deployer](https://deployer.org/) and [deployer-tools](https://github.com/move-elevator/deployer-tools) as deployment base.
7071

@@ -97,7 +98,7 @@ Includes:
9798
- `deploy/deploy-stage.yaml`
9899

99100
> [!NOTE]
100-
> Use this template if the project wants a simple stage deployment and doesn't need an advanced feature branch deployment.
101+
> Use this template if the project wants a simple stage deployment and doesn't need an advanced feature branch deployment.
101102

102103
### Release
103104

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Purpose:
2+
# Analyze job for simply linting all content block config files
3+
#
4+
# Dependency:
5+
# Composer package "friendsoftypo3/content-blocks" and a composer script "lint:content-blocks"
6+
#
7+
analyze:content-blocks:lint:
8+
image:
9+
name: ${DEFAULT_IMAGE_BUILD_COMPOSER}
10+
stage: analyze
11+
needs:
12+
- build:php
13+
script:
14+
- composer run lint:content-blocks
15+
rules:
16+
- if: $CI_PIPELINE_SOURCE == "web"
17+
when: always
18+
- if: $CI_COMMIT_TAG || $CI_PIPELINE_SOURCE == "schedule" || $CI_PIPELINE_SOURCE == "pipeline" || $CI_PIPELINE_SOURCE == "merge_request_event"
19+
when: never
20+
- if: $CI_COMMIT_TAG == null
21+
changes:
22+
- "**/ContentBlocks/**/*.yaml"

0 commit comments

Comments
 (0)