From 32235eaf83620cf4c7d80142d8a41611b8f61f86 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Harper?= Date: Wed, 23 Aug 2023 18:06:20 -0400 Subject: [PATCH] make GitHub Action Syntax Check fail when vale find issues the 'fail_on_error' option of reviewdog didn't work. See https://github.com/errata-ai/vale-action/issues/103 --- .github/workflows/check-syntax.yml | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/.github/workflows/check-syntax.yml b/.github/workflows/check-syntax.yml index ee060b33..b2185b98 100644 --- a/.github/workflows/check-syntax.yml +++ b/.github/workflows/check-syntax.yml @@ -10,8 +10,17 @@ jobs: - name: Checkout this repository uses: actions/checkout@v3.5.3 - - name: Validate the syntax - uses: errata-ai/vale-action@reviewdog + - name: Get latest version of Vale + id: lastversion + uses: dvershinin/lastversion-action@v0.0.3 with: - fail_on_error: true - vale_flags: "--config=.vale.ini" + repository: errata-ai/vale + + - name: Install Vale + run: | + wget https://github.com/errata-ai/vale/releases/download/v${{ steps.lastversion.outputs.last_version }}/vale_${{ steps.lastversion.outputs.last_version }}_Linux_64-bit.tar.gz -O vale.tar.gz + tar -xvzf vale.tar.gz vale + rm vale.tar.gz + + - name: Validate the syntax + run: ./vale --config=.vale.ini *.md