From 897f86da55cf9725e29fe65f06de59141338a7b5 Mon Sep 17 00:00:00 2001 From: "E. G. Patrick Bos" Date: Wed, 16 Mar 2022 15:40:25 +0100 Subject: [PATCH] add separate documentation GA workflow --- .../.github/workflows/build.yml | 3 -- .../.github/workflows/documentation.yml | 36 +++++++++++++++++++ 2 files changed, 36 insertions(+), 3 deletions(-) create mode 100644 {{cookiecutter.directory_name}}/.github/workflows/documentation.yml diff --git a/{{cookiecutter.directory_name}}/.github/workflows/build.yml b/{{cookiecutter.directory_name}}/.github/workflows/build.yml index 48612f94..bb0c464f 100644 --- a/{{cookiecutter.directory_name}}/.github/workflows/build.yml +++ b/{{cookiecutter.directory_name}}/.github/workflows/build.yml @@ -37,9 +37,6 @@ jobs: run: pytest -v - name: Verify that we can build the package run: python3 setup.py sdist bdist_wheel - - name: Build documentation - run: make coverage doctest html - working-directory: docs lint: name: Linting build diff --git a/{{cookiecutter.directory_name}}/.github/workflows/documentation.yml b/{{cookiecutter.directory_name}}/.github/workflows/documentation.yml new file mode 100644 index 00000000..a9f7b367 --- /dev/null +++ b/{{cookiecutter.directory_name}}/.github/workflows/documentation.yml @@ -0,0 +1,36 @@ +name: documentation + +on: + push: + branches: + - main + pull_request: + branches: + - main + +jobs: + build-documentation: + name: Build documentation + runs-on: ubuntu-latest + strategy: + fail-fast: false + steps: + - uses: actions/checkout@v2 + - name: Set up Python 3.9 + uses: actions/setup-python@v2 + with: + python-version: 3.9 + - name: Python info + shell: bash -l {0} + run: | + which python3 + python3 --version + - name: Upgrade pip and install dependencies + run: | + python3 -m pip install --upgrade pip setuptools + python3 -m pip install .[dev,publishing] + - name: Install pandoc using apt + run: sudo apt install pandoc + - name: Build documentation + run: make coverage doctest html + working-directory: docs \ No newline at end of file