Skip to content

Commit 2ea08c2

Browse files
feat(COD-5174): only store the findings on push (#224)
1 parent 6480646 commit 2ea08c2

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

action.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ inputs:
77
required: false
88
default: '.'
99
target:
10-
description: 'One of old or new to represent which is being analyzed'
10+
description: 'One of push, old or new to represent which is being analyzed'
1111
required: false
1212
debug:
1313
description: 'Set to true to enable debug logging'

src/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,6 @@ async function runAnalysis() {
5151
'sca',
5252
'scan',
5353
'.',
54-
'--save-results',
5554
'-o',
5655
scaDir,
5756
'--formats',
@@ -61,6 +60,9 @@ async function runAnalysis() {
6160
'--keyring',
6261
trustedKeys,
6362
]
63+
if (target === 'push') {
64+
args.push('--save-results')
65+
}
6466
if (indirectDeps.toLowerCase() === 'false') {
6567
args.push('--eval-direct-only')
6668
}

0 commit comments

Comments
 (0)