From 1a7d2a4dc57c1f2de5a4e87ac1e371eb86167518 Mon Sep 17 00:00:00 2001 From: Griatch Date: Sat, 19 Sep 2020 16:25:18 +0200 Subject: [PATCH] Test doc-build action --- .../workflows/github_action_build_docs.yml | 45 +++++++++++++++++++ ...ction.yml => github_action_test_suite.yml} | 30 +------------ docs/Makefile | 2 +- 3 files changed, 48 insertions(+), 29 deletions(-) create mode 100644 .github/workflows/github_action_build_docs.yml rename .github/workflows/{github_evennia_action.yml => github_action_test_suite.yml} (81%) diff --git a/.github/workflows/github_action_build_docs.yml b/.github/workflows/github_action_build_docs.yml new file mode 100644 index 0000000000..36ce83886e --- /dev/null +++ b/.github/workflows/github_action_build_docs.yml @@ -0,0 +1,45 @@ +# This github-Evennia workflow will build the docs. + +name: documentation + +on: + push: + branches: [ master, develop ] + paths: + - 'docs/source/**' + pull_request: + branches: [ master, develop ] + paths: + - 'docs/source/**' + +jobs: + build: + runs-on: ubuntu-latest + + strategy: + matrix: + python-version: [3.7] + TESTING_DB: ['sqlite3'] + + steps: + - uses: actions/checkout@v2 + + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + + - name: Install package dependencies + run: | + python -m pip install --upgrade pip + cd docs/ + make install + + - name: Quick-test docs (no autodocs) + run: | + make quick + + - name: Deploy docs (only from master/develop branch) + if: ${{ github.ref == 'refs/heads/develop' || github.ref == 'refs/heads/master'}} + run: | + echo "Would deploy here!" diff --git a/.github/workflows/github_evennia_action.yml b/.github/workflows/github_action_test_suite.yml similarity index 81% rename from .github/workflows/github_evennia_action.yml rename to .github/workflows/github_action_test_suite.yml index 40de021997..8a711c03a8 100644 --- a/.github/workflows/github_evennia_action.yml +++ b/.github/workflows/github_action_test_suite.yml @@ -6,6 +6,8 @@ name: test-suite on: push: branches: [ master, develop ] + paths-ignore: + - 'docs/source/**' pull_request: branches: [ master, develop ] @@ -105,31 +107,3 @@ jobs: with: project-token: ${{ secrets.CODACY_PROJECT_TOKEN }} coverage-reports: ./testing_mygame/coverage.xml - - one: - runs-on: ubuntu-latest - steps: - - name: Dump GitHub context - env: - GITHUB_CONTEXT: ${{ toJson(github) }} - run: echo "$GITHUB_CONTEXT" - - name: Dump job context - env: - JOB_CONTEXT: ${{ toJson(job) }} - run: echo "$JOB_CONTEXT" - - name: Dump steps context - env: - STEPS_CONTEXT: ${{ toJson(steps) }} - run: echo "$STEPS_CONTEXT" - - name: Dump runner context - env: - RUNNER_CONTEXT: ${{ toJson(runner) }} - run: echo "$RUNNER_CONTEXT" - - name: Dump strategy context - env: - STRATEGY_CONTEXT: ${{ toJson(strategy) }} - run: echo "$STRATEGY_CONTEXT" - - name: Dump matrix context - env: - MATRIX_CONTEXT: ${{ toJson(matrix) }} - run: echo "$MATRIX_CONTEXT" diff --git a/docs/Makefile b/docs/Makefile index de813e0401..1433a6a6ec 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -56,7 +56,7 @@ _multiversion-check-env: _clean_api_index: rm source/api/* -# remove supervluous 'module' and 'package' text from api headers +# remove superfluos 'module' and 'package' text from api headers _reformat_apidoc_headers: for f in source/api/*.rst; do\ perl -pi -e 's/(module|package)$$// if $$. == 1' $$f ;\