From bf0cb7fac463578c319089fbf395856e959e9fea Mon Sep 17 00:00:00 2001 From: Federico Builes Date: Mon, 19 Sep 2022 17:28:20 +0200 Subject: [PATCH] Add a default config file. --- .github/dependency-review-config.yml | 1 + src/config.ts | 2 +- src/schemas.ts | 1 + 3 files changed, 3 insertions(+), 1 deletion(-) create mode 100644 .github/dependency-review-config.yml diff --git a/.github/dependency-review-config.yml b/.github/dependency-review-config.yml new file mode 100644 index 0000000..94dfd0a --- /dev/null +++ b/.github/dependency-review-config.yml @@ -0,0 +1 @@ +fail-on-severity: low diff --git a/src/config.ts b/src/config.ts index 3f78c3a..efcc7ea 100644 --- a/src/config.ts +++ b/src/config.ts @@ -5,7 +5,7 @@ import * as core from '@actions/core' import * as z from 'zod' import {ConfigurationOptions, SEVERITIES} from './schemas' -export const CONFIG_FILEPATH = './.github/dependency-review.yml' +export const CONFIG_FILEPATH = './.github/dependency-review-config.yml' function getOptionalInput(name: string): string | undefined { const value = core.getInput(name) diff --git a/src/schemas.ts b/src/schemas.ts index 90f7517..1300cd5 100644 --- a/src/schemas.ts +++ b/src/schemas.ts @@ -35,6 +35,7 @@ export const ConfigurationOptionsSchema = z fail_on_severity: z.enum(SEVERITIES).default('low'), allow_licenses: z.array(z.string()).default([]), deny_licenses: z.array(z.string()).default([]), + config_file: z.string().optional().default('false'), base_ref: z.string(), head_ref: z.string() })