-
Notifications
You must be signed in to change notification settings - Fork 36
48 lines (36 loc) · 1.14 KB
/
action.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
# This workflow tests github action feature and integration
name: ActionTest
on:
push:
branches: [ main ]
jobs:
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
ActionTest:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
with:
ref: ${{ github.event.pull_request.head.sha }}
- name: CredSweeper test
# TODO: change @action to release point with the action
uses: Samsung/CredSweeper@main
with:
# args - arguments to credsweeper tool. See default values in action.yml
args: --path ./tests/samples/ --save-json
- name: Prepare commit status
run: |
ITEMS_CNT=$(jq '. | length' output.json)
if [ 1 -lt ${ITEMS_CNT} ]; then
echo "Samples were successfully scanned"
else
echo "Unexpected items: ${ITEMS_CNT}"
exit 1
fi
- name: CredSweeper report
if: always()
uses: actions/upload-artifact@v3
with:
name: output.json
path: output.json
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #