From 673c15d9d645372eedf60d7a8bfd7bae6db3af4c Mon Sep 17 00:00:00 2001
From: Moul <moul@moul.re>
Date: Sat, 27 Apr 2019 12:50:35 +0200
Subject: [PATCH] [ci] Do not trigger build, tests, type check on modification
 of non-relevant files

---
 .gitlab-ci.yml | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 32a1b893..22a0fd66 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -37,8 +37,21 @@ push_to_github:
     - eval "$(pyenv init -)"
     - pyenv shell $PYENV_PYTHON_VERSION
 
+.changes: &changes
+  except:
+    changes:
+      - CHANGELOG.md
+      - ci/*
+      - config
+      - docs
+      - LICENSE*
+      - Makefile
+      - README*
+      - release.sh
+
 build: &build
   <<: *pyenv
+  <<: *changes
   stage: build
   script:
     - pip install -r requirements.txt
@@ -47,6 +60,7 @@ build: &build
 
 test:
   <<: *pyenv
+  <<: *changes
   stage: test
   script:
     - pip install coveralls
@@ -55,6 +69,7 @@ test:
 
 mypy:
   <<: *pyenv
+  <<: *changes
   stage: test
   script:
     - pip install -r requirements_dev.txt
-- 
GitLab