diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 7c05a7086bbcfde6b60ee4a9121b719becb6d251..84c3108f07dc20a6161e625f75cd8755fb03e0b5 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -14,12 +14,9 @@ build:
   artifacts:
     when: always
     paths:
-      - $FILEDIR/$FILENAME.pdf
-      - $FILEDIR/build_$FILENAME.log
-  script:
-    - cd "$FILEDIR"
-    - latexmk -pdf "$FILENAME.tex" 2>&1 | tee build_"$FILENAME".log
-    - 'grep -v "LaTeX Warning: There were undefined references." build_"$FILENAME".log'
+      - thesis.pdf
+      - thesis.log
+  script: make
 
 diff:
   stage: diff