Skip to content

Commit 7b928c5

Browse files
Create slither.yml
adding slither
1 parent 699b0cb commit 7b928c5

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

.github/workflows/slither.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Slither Analysis
2+
on: [push]
3+
jobs:
4+
analyze:
5+
runs-on: ubuntu-latest
6+
permissions:
7+
security-events: write
8+
contents: read
9+
steps:
10+
- uses: actions/checkout@v3
11+
12+
- name: Run Slither
13+
uses: crytic/slither-action@v0.3.0
14+
id: slither
15+
with:
16+
node-version: 16
17+
fail-on: none
18+
slither-args: --filter-paths "openzeppelin,RIF,util" --exclude .github --checklist --markdown-root ${{ github.server_url }}/${{ github.repository }}/blob/${{ github.sha }}/
19+
target: .
20+
21+
- name: Create Slack payload
22+
id: create-slack-payload
23+
run: |
24+
npm install -g md-to-pdf
25+
touch slither-output.md
26+
echo -n '${{steps.slither.outputs.stdout }}' > slither-output.md
27+
md-to-pdf slither-output.md > slither-output.pdf
28+
29+
30+
- uses: MeilCli/slack-upload-file@v3
31+
with:
32+
slack_token: ${{ secrets.SLACK_TOKEN }}
33+
channel_id: 'C05UBKD9Y65'
34+
file_path: 'slither-output.pdf'
35+
initial_comment: 'Slither scan results for ${{github.repository}}'
36+

0 commit comments

Comments
 (0)