Skip to content

Commit 8dd3824

Browse files
authored
chore: update readme
1 parent df68252 commit 8dd3824

File tree

1 file changed

+48
-2
lines changed

1 file changed

+48
-2
lines changed

README.md

Lines changed: 48 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,60 @@
77

88
---
99

10-
TODO
10+
## Usage
1111

12-
**Example annotation output**:
12+
```yaml
13+
name: "analyze"
14+
on: # rebuild any PRs and main branch changes
15+
pull_request:
16+
push:
17+
branches:
18+
- main
19+
20+
jobs:
21+
dart: # make sure the action works on a clean machine without building
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v2
25+
- uses: dart-lang/setup-dart@v1
26+
- uses: invertase/github-action-dart-analyzer@v1
27+
with:
28+
# (Optional) Treat info level issues as fatal.
29+
fatal-infos: false
30+
31+
# (Optional) Treat warning level issues as fatal
32+
# (defaults to true).
33+
fatal-warnings: false
34+
35+
# (Optional) Whether to add annotations to GitHub actions summary / PR
36+
# review files.
37+
# (defaults to true).
38+
annotate: true
39+
40+
# (Optional) If set to true only annotations will be created and the
41+
# GitHub action itself will not fail on Dart analyzer problems.
42+
# (defaults to false).
43+
annotate-only: false
44+
45+
# (Optional) The working directory to run the Dart analyzer in
46+
# (defaults to `./`).
47+
working-directory: ./
48+
```
49+
50+
51+
## Screenshots
52+
53+
**Example annotation output in PR changes review**:
1354
1455
1) ![image](https://user-images.githubusercontent.com/5347038/149161220-dbd92743-2cdc-4083-b7f2-31ed9ca7f855.png)
1556
2) ![image](https://user-images.githubusercontent.com/5347038/149161397-d6a72437-a15f-4dbb-a6b5-227bd11da210.png)
1657
3) ![image](https://user-images.githubusercontent.com/5347038/149161493-66e2b7f6-177a-4daa-bb66-9d0a26ba391d.png)
1758
59+
**Example annotation output in check summary**:
60+
61+
![image](https://user-images.githubusercontent.com/5347038/149163192-e7f97894-cd1c-4892-92be-580f121a9aef.png)
62+
63+
1864
**Example workflow logs output**:
1965
2066
![image](https://user-images.githubusercontent.com/5347038/149162346-573bf836-489f-458f-8501-60148d2104cd.png)

0 commit comments

Comments
 (0)