Skip to content

Commit

Permalink
Adds semgrep rules
Browse files Browse the repository at this point in the history
  • Loading branch information
gdavison committed Oct 25, 2024
1 parent 50097a9 commit 9543595
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions .ci/semgrep/stdlib/sort.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
rules:
- id: prefer-slices-sortfunc
languages: [go]
message: Prefer slices.SortFunc to sort.Slice
pattern: sort.Slice(...)
severity: WARNING

- id: prefer-slices-sortstablefunc
languages: [go]
message: Prefer slices.SortStableFunc to sort.SliceStable
pattern: sort.SliceStable(...)
severity: WARNING

0 comments on commit 9543595

Please sign in to comment.