]> Frank Brehm's Git Trees - pixelpark/python-packaging.git/commitdiff
Adding .gitlab-ci.yml
authorFrank Brehm <frank@brehm-online.com>
Thu, 29 Dec 2022 09:08:04 +0000 (10:08 +0100)
committerFrank Brehm <frank@brehm-online.com>
Thu, 29 Dec 2022 09:08:04 +0000 (10:08 +0100)
.gitlab-ci.yml [new file with mode: 0644]

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644 (file)
index 0000000..dc0b0c4
--- /dev/null
@@ -0,0 +1,27 @@
+---
+
+stages:
+  - linter
+
+include:
+  - local: /gitlab/python-setup-template.yaml
+
+YAML-linter:
+  stage: linter
+  extends: .setup-python-environment
+  image: python:3.11
+  rules:
+    - if: '$CI_COMMIT_TAG'
+    - if: $CI_COMMIT_BRANCH == "master"
+    - if: $CI_COMMIT_BRANCH == "main"
+    - if: $CI_COMMIT_BRANCH == "test"
+    - if: $CI_COMMIT_BRANCH =~ /test-.*/
+    - if: $CI_COMMIT_BRANCH =~ /build.*/
+    - if: $CI_COMMIT_BRANCH == "develop"
+  tags:
+    - docker
+  script:
+    - apt install --yes yamllint
+    - yamllint --config-file .yamllint.yaml --strict --format colored .gitlab-ci.yml gitlab
+
+# vim: et tabstop=2 expandtab shiftwidth=2 softtabstop=2 list