From d0300352dad825fa7054cf0ae13f0f3f9c8e08a6 Mon Sep 17 00:00:00 2001 From: lblythen Date: Mon, 14 Aug 2023 10:40:09 +1200 Subject: [PATCH] feat: refactor woke for SSoT - Replace woke command in GitHub action with call to existing make woke - Makefile needs sudo to install Snap if woke missing - Missing-woke problem solved by sudo snap install; no need for error exit --- .github/workflows/automatic-doc-checks.yml | 16 +++++++++------- Makefile | 2 +- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/.github/workflows/automatic-doc-checks.yml b/.github/workflows/automatic-doc-checks.yml index 173f8e03..5125782a 100644 --- a/.github/workflows/automatic-doc-checks.yml +++ b/.github/workflows/automatic-doc-checks.yml @@ -37,13 +37,15 @@ jobs: - name: Checkout uses: actions/checkout@v3 - - name: woke - uses: get-woke/woke-action@v0 - with: - # Cause the check to fail on any broke rules - fail-on-error: true - workdir: . - woke-args: "*.rst **/*.rst -c https://github.com/canonical-web-and-design/Inclusive-naming/raw/main/config.yml" + - name: Install the doc framework + working-directory: . + run: | + make install + + - name: Run incluse-language checker + working-directory: . + run: | + make woke linkcheck: name: Link check diff --git a/Makefile b/Makefile index d091d074..dcf383a4 100644 --- a/Makefile +++ b/Makefile @@ -54,7 +54,7 @@ linkcheck: . $(VENV) ; $(SPHINXBUILD) -c . -b linkcheck "$(SOURCEDIR)" "$(BUILDDIR)" woke: - type woke >/dev/null 2>&1 || { snap install woke; exit 1; } + type woke >/dev/null 2>&1 || { sudo snap install woke; } woke *.rst **/*.rst -c https://github.com/canonical-web-and-design/Inclusive-naming/raw/main/config.yml .PHONY: help Makefile