Skip to content

test vale gha pr

test vale gha pr #181

Workflow file for this run

name: Lint and suggest
on:
pull_request:
paths:
- '**/*.md'
permissions:
contents: read
pull-requests: write
jobs:
vale: # Vale linting job
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
fetch-depth: 0 # Fetch all history so we can access all commits
- name: Install Vale
uses: errata-ai/vale-action@v2
- name: Install jq
run: sudo apt-get install -y jq
- name: Run Vale on changed files
run: |
for file in $(git diff --name-only --cached); do
echo "Running Vale on $file"
vale --output=JSON $file > "vale_output_${file//\//_}.json"
vale --output=edit $file > "vale_output_${file//\//_}_edit.md"
done
echo "Vale outputs:"
ls -l
- name: Suggest changes from Vale
uses: parkerbxyz/suggest-changes@v1
with:
comment: 'Please review and consider the suggested changes from Vale.' # Optional comment