]> git.ipfire.org Git - thirdparty/paperless-ngx.git/commitdiff
update ci for documentation build vs deploy
authorMichael Shamoon <4887959+shamoon@users.noreply.github.com>
Fri, 2 Dec 2022 17:09:29 +0000 (09:09 -0800)
committerMichael Shamoon <4887959+shamoon@users.noreply.github.com>
Fri, 2 Dec 2022 23:13:44 +0000 (15:13 -0800)
.github/workflows/ci.yml

index fae7b7b1108dc92bf9dd4640c0ab1e155b1791de..19bbfd0d7ca2ea7eb59fe0e59e39cf56e714b647 100644 (file)
@@ -37,6 +37,46 @@ jobs:
     runs-on: ubuntu-20.04
     needs:
       - pre-commit
+    steps:
+      -
+        name: Checkout
+        uses: actions/checkout@v3
+      -
+        name: Install pipenv
+        run: |
+          pipx install pipenv==2022.10.12
+      -
+        name: Set up Python
+        uses: actions/setup-python@v4
+        with:
+          python-version: 3.8
+          cache: "pipenv"
+          cache-dependency-path: 'Pipfile.lock'
+      -
+        name: Install dependencies
+        run: |
+          pipenv sync --dev
+      -
+        name: List installed Python dependencies
+        run: |
+          pipenv run pip list
+      -
+        name: Make documentation
+        run: |
+          pipenv run mkdocs build --config-file ./mkdocs.yml
+      -
+        name: Upload artifact
+        uses: actions/upload-artifact@v3
+        with:
+          name: documentation
+          path: site/
+
+  documentation-deploy:
+    name: "Deploy Documentation"
+    runs-on: ubuntu-20.04
+    if: github.event_name == 'push' && github.ref == 'refs/heads/main'
+    needs:
+      - documentation
     steps:
       -
         name: Checkout