[gnome-shell/zbrown/docgen] ci: Build docs in CI




commit 2ec728ab354ddf352bc5729682af5b1b68557d72
Author: Zander Brown <zbrown gnome org>
Date:   Mon Jun 7 01:10:28 2021 +0100

    ci: Build docs in CI

 .gitlab-ci.yml | 43 +++++++++++++++++++++++++++++++++++++++----
 1 file changed, 39 insertions(+), 4 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 78f380aa41..2045b84c24 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -7,8 +7,10 @@ stages:
  - pre_review
  - prep
  - review
+ - pre-build
  - build
  - test
+ - docs
  - deploy
 
 default:
@@ -178,13 +180,21 @@ no_template_check:
     script:
         - ./.gitlab-ci/check-template-strings.sh
 
-build:
-    stage: build
+mutter:
+    stage: pre-build
     needs: ["check_commit_log"]
-    before_script:
+    script:
         - .gitlab-ci/checkout-mutter.sh
         - meson mutter mutter/build --prefix=/usr -Dtests=false
         - ninja -C mutter/build install
+    artifacts:
+        expire_in: 1 day
+        paths:
+            - mutter
+
+build:
+    stage: build
+    needs: ["mutter"]
     script:
         - meson . build -Dbuildtype=debugoptimized -Dman=false --werror
         - ninja -C build
@@ -192,7 +202,6 @@ build:
     artifacts:
         expire_in: 1 day
         paths:
-            - mutter
             - build
 
 test:
@@ -227,3 +236,29 @@ nightly:
   extends: '.publish_nightly'
   variables:
     BUNDLES: '$BUNDLE'
+
+reference:
+    stage: docs
+    needs: ["mutter"]
+    before_script:
+        - pip install markdown toml typogrify
+    script:
+        - meson -Dman=false -Dgtk_doc=true build
+        - ninja -C build
+        - mkdir -p reference/
+        - mv build/docs/St/ reference/
+        - mv build/docs/Shell/ reference/
+    artifacts:
+        paths:
+            - reference
+
+pages:
+    stage: deploy
+    needs: ['reference']
+    script:
+        - mv reference/ public/
+    artifacts:
+        paths:
+             - public
+    only:
+        - master


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]