You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/content/Running during CI.md
+11
Original file line number
Diff line number
Diff line change
@@ -42,6 +42,7 @@ Example when using MSBuild:
42
42
43
43
## GitHub Actions
44
44
45
+
### GitHub Advanced Security
45
46
If you are using [GitHub Actions](https://docs.github.com/en/code-security/codeql-cli/using-the-advanced-functionality-of-the-codeql-cli/sarif-output) you can easily send the *sarif file* to [CodeQL](https://codeql.github.com/).
46
47
47
48
```yml
@@ -68,4 +69,14 @@ Sample:
68
69
69
70
See [fsproject/fantomas#2962](https://github.com/fsprojects/fantomas/pull/2962) for more information.
70
71
72
+
### Github Workflow Commands
73
+
If you cannot use GitHub Advanced Security (e.g. if your repository is private), you can get similar annotations by running the analyzers with `--output-format github`.
74
+
This will make the analyzers print their results as [GitHub Workflow Commands](https://docs.github.com/en/actions/writing-workflows/choosing-what-your-workflow-does/workflow-commands-for-github-actions).
75
+
If you for instance have a GitHub Action to run analyzers on every pull request, these annotations will show up in the "Files changed" on the pull request.
76
+
If the annotations don't show correctly, you might need to set the `code-root` to the root of the repository.
77
+
78
+
Note that GitHub has a hard limit of 10 annotations of each type (notice, warning, error) per CI step.
79
+
This means that only the first 10 errors, the first 10 warnings and the first 10 hints/info results from analyzers will generate annotations.
80
+
The workflow log will contain all analyzer results even if a job hits the annotation limits.
0 commit comments