File tree Expand file tree Collapse file tree 1 file changed +25
-17
lines changed Expand file tree Collapse file tree 1 file changed +25
-17
lines changed Original file line number Diff line number Diff line change 2
2
3
3
name : Docs-Linting
4
4
5
- # Controls when the action will run.
6
- on :
7
- # Triggers the workflow on push or pull request events but only for the main branch
8
- push :
9
- branches : [ main ]
10
-
11
- # Allows you to run this workflow manually from the Actions tab
12
- workflow_dispatch :
5
+ on :
6
+ pull_request :
7
+ paths :
8
+ - ' docs/**'
9
+ - ' .github/workflows/vale.yml'
13
10
14
11
jobs :
15
- prose :
12
+ vale :
13
+ name : Linting with Vale
16
14
runs-on : ubuntu-latest
15
+ permissions :
16
+ actions : read
17
+ checks : read
18
+ contents : read
19
+ pull-requests : read
17
20
steps :
18
- - name : Checkout
19
- uses : actions/checkout@master
20
-
21
- - name : Vale
22
-
23
- with :
24
- debug : true
21
+ - uses : actions/checkout@v4
22
+ - name : Install Asciidoctor
23
+ run : sudo apt-get install -y asciidoctor
24
+ - uses : errata-ai/vale-action@reviewdog
25
+ with :
26
+ filter_mode : diff_context
27
+ vale_flags : " --no-exit --minAlertLevel=error --glob=*.adoc"
28
+ reporter : github-pr-review
29
+ fail_on_error : true
25
30
env :
26
- GITHUB_TOKEN : ${{secrets.GITHUB_TOKEN}}
31
+ # Required, set by GitHub actions automatically:
32
+ # https://docs.github.com/en/actions/security-guides/automatic-token-authentication#about-the-github_token-secret
33
+ GITHUB_TOKEN : ${{secrets.GITHUB_TOKEN}}
34
+ REVIEWDOG_GITHUB_API_TOKEN : ${{secrets.GITHUB_TOKEN}}
You can’t perform that action at this time.
0 commit comments