diff --git a/.github/workflows/append-changelog.yml b/.github/workflows/append-changelog.yml index be984cb..ea078be 100644 --- a/.github/workflows/append-changelog.yml +++ b/.github/workflows/append-changelog.yml @@ -15,7 +15,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - name: Write changelog run: | @@ -49,7 +49,7 @@ jobs: rm -fv CHANGELOG.md.bak - name: Commit & push changes - uses: EndBug/add-and-commit@v8 + uses: EndBug/add-and-commit@v9 with: author_name: github-actions[bot] author_email: github-actions[bot]@users.noreply.github.com diff --git a/.github/workflows/check.yml b/.github/workflows/check.yml index 7bb15a0..ca626e3 100644 --- a/.github/workflows/check.yml +++ b/.github/workflows/check.yml @@ -1,29 +1,45 @@ -name: Check +name: Markdown Lint & Spellcheck on: workflow_dispatch: push: + branches: + - '**' paths: - 'CHANGELOG.md' + - '.markdownlint.json' - '.aspell.*.pws' jobs: markdownlint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: DavidAnson/markdownlint-cli2-action@v9 + - uses: actions/checkout@v4 + - uses: DavidAnson/markdownlint-cli2-action@v16 with: globs: 'CHANGELOG.md' - spellchecker: + + spellcheck: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 + - uses: actions/checkout@v4 - name: Setup aspell - run: sudo apt-get -y update && sudo apt-get -y install aspell aspell-en - - name: Run spellchecker run: | - SPELLCHECK_OUT=$(cat CHANGELOG.md \ - | aspell --lang=en --encoding=utf-8 --personal=./.aspell.en.pws list) - echo $SPELLCHECK_OUT - test $(echo -n $SPELLCHECK_OUT | wc -c) -eq 0 + sudo apt-get -y update + sudo apt-get -y install aspell aspell-en + - name: Run spellcheck + run: | + set -eux + temp=$(mktemp) + cat CHANGELOG.md \ + | aspell \ + --lang=en \ + --encoding=utf-8 \ + --personal=./.aspell.en.pws \ + list \ + | sort -u \ + > $temp + if [ -s $temp ]; then + cat $temp + exit 1 + fi diff --git a/.github/workflows/update-submodules.yml b/.github/workflows/update-submodules.yml index 9841bf4..9f122ea 100644 --- a/.github/workflows/update-submodules.yml +++ b/.github/workflows/update-submodules.yml @@ -9,7 +9,7 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 with: token: ${{ secrets.PUSH_TOKEN }}