From 3da990943051d2059bfdf4ee16ae494fa95bc7c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ond=C5=99ej=20Sur=C3=BD?= Date: Tue, 7 Jul 2020 16:15:59 +0200 Subject: [PATCH] Fail the build if it updates any of the files in the git repository There are still some pregenerated files left in the git repository (cleaned up during `make maintainer-clean`) and we currently don't notice if any of those needs to be updated in the git repository because we ignore changes in the repository done during the build. This commit adds a safeguard that fails the build job if the contents of the git repository gets modified during the build. --- .gitlab-ci.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 15a7693b40..0366061a71 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -201,6 +201,7 @@ stages: - make -j${BUILD_PARALLEL_JOBS:-1} -k all V=1 - test -z "${RUN_MAKE_INSTALL}" || make install - test -z "${RUN_MAKE_INSTALL}" || sh util/check-make-install + - if test "$(git status --porcelain | grep -Ev '\?\?' | wc -l)" -gt "0"; then git status --short; exit 1; fi needs: - job: autoreconf artifacts: true