mirror of
https://github.com/renovatebot/github-action.git
synced 2025-12-16 08:52:35 +00:00
feat: allow override env regex (#692)
This commit is contained in:
parent
5f40203468
commit
62d65f0924
3 changed files with 32 additions and 1 deletions
|
|
@ -26,9 +26,11 @@ class Input {
|
|||
private readonly _configurationFile: Readonly<EnvironmentVariable>;
|
||||
|
||||
constructor() {
|
||||
const envRegexInput = core.getInput('env-regex');
|
||||
const envRegex = envRegexInput ? new RegExp(envRegexInput) : this.options.envRegex;
|
||||
this._environmentVariables = new Map(
|
||||
Object.entries(process.env).filter(([key]) =>
|
||||
this.options.envRegex.test(key)
|
||||
envRegex.test(key)
|
||||
)
|
||||
);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue