updating production flag to --omit=dev (#125)

* updating production flag to --omit=dev

* fixing readme comment
This commit is contained in:
William Barnes
2022-07-09 05:08:36 -04:00
committed by GitHub
parent 3e3735791c
commit 5b91df5581
4 changed files with 4 additions and 4 deletions

View File

@@ -23,7 +23,7 @@ If vulnerabilities are found by `npm audit`, Action triggered by push, schedule
|Parameter|Required|Default Value|Description|
|:--:|:--:|:--:|:--|
|audit_level|false|low|The value of `--audit-level` flag|
|production_flag|false|false|Runnning `npm audit` with `--production`|
|production_flag|false|false|Runnning `npm audit` with `--omit=dev`|
|json_flag|false|false|Runnning `npm audit` with `--json`|
|issue_assignees|false|N/A|Issue assignees (separated by commma)|
|issue_labels|false|N/A|Issue labels (separated by commma)|

View File

@@ -7,7 +7,7 @@ inputs:
default: low
required: false
production_flag:
description: 'Run npm audit with --production'
description: 'Run npm audit with --omit=dev'
default: 'false'
required: false
json_flag:

2
dist/index.js vendored
View File

@@ -25,7 +25,7 @@ class Audit {
const isWindowsEnvironment = process.platform == "win32";
const cmd = (isWindowsEnvironment) ? 'npm.cmd' : 'npm';
if (productionFlag === 'true') {
auditOptions.push('--production');
auditOptions.push('--omit=dev');
}
if (jsonFlag === 'true') {
auditOptions.push('--json');

View File

@@ -19,7 +19,7 @@ export class Audit {
const cmd: string = isWindowsEnvironment ? 'npm.cmd' : 'npm'
if (productionFlag === 'true') {
auditOptions.push('--production')
auditOptions.push('--omit=dev')
}
if (jsonFlag === 'true') {