]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
ci: Add documentation build job
authorJoel Rosdahl <joel@rosdahl.net>
Sun, 17 Aug 2025 12:21:23 +0000 (14:21 +0200)
committerJoel Rosdahl <joel@rosdahl.net>
Sun, 31 Aug 2025 08:30:48 +0000 (10:30 +0200)
.github/workflows/build.yaml
ci/build-docs [new file with mode: 0755]

index 3502d94dd3a766ffabc95c880be4e3939157b466..d4345779f71e909de64a5a81a253e303bee6f1d3 100644 (file)
@@ -255,6 +255,30 @@ jobs:
           name: ${{ matrix.sys }}-${{ matrix.compiler }}-testdir.tar.xz
           path: testdir.tar.xz
 
+  build_documentation:
+    timeout-minutes: 30
+    name: Documentation
+    runs-on: ubuntu-24.04
+    env:
+      CMAKE_GENERATOR: Ninja
+    steps:
+      - name: Get source
+        uses: actions/checkout@v4
+      - name: Prepare environment
+        run: |
+          sudo apt-get install -y asciidoctor
+      - name: Build documentation
+        run: ci/build-docs
+      - name: Upload documentation
+        uses: actions/upload-artifact@v4
+        with:
+          name: docs
+          path: |
+            doc/INSTALL.md
+            GPL-3.0.txt
+            install
+            README.md
+
   build_linux_aarch64_binary:
     timeout-minutes: 30
     name: Linux aarch64 binary
@@ -507,18 +531,6 @@ jobs:
             SPECIAL: build-and-verify-source-package
             apt_get: elfutils libzstd-dev libhiredis-dev asciidoctor
 
-          - name: HTML documentation
-            os: ubuntu-22.04
-            EXTRA_CMAKE_BUILD_FLAGS: --target doc-html
-            RUN_TESTS: none
-            apt_get: libzstd-dev libhiredis-dev asciidoctor
-
-          - name: Manual page
-            os: ubuntu-22.04
-            EXTRA_CMAKE_BUILD_FLAGS: --target doc-man-page
-            RUN_TESTS: none
-            apt_get: libzstd-dev libhiredis-dev asciidoctor
-
           - name: Clang-Tidy
             os: ubuntu-22.04
             CC: clang-12
diff --git a/ci/build-docs b/ci/build-docs
new file mode 100755 (executable)
index 0000000..2a9d42d
--- /dev/null
@@ -0,0 +1,7 @@
+#!/bin/sh
+
+set -eu
+
+dir=build
+cmake -B "${dir}" -D CMAKE_INSTALL_PREFIX="$(pwd)/install"
+ninja -C "${dir}" doc/install