Skip to content

Commit 46bd9bc

Browse files
committed
wip
1 parent a419317 commit 46bd9bc

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

action.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,19 @@ const stripQuotes = (str) =>
1313
const replaceEnvVars = (str) => {
1414
const value = str
1515
.replaceAll(
16-
/\$\{([a-zA-Z0-9_]+):\+:\$[a-zA-Z0-9_]+\}/g,
16+
/\$\{([a-zA-Z0-9_]+):[+-]:\$[a-zA-Z0-9_]+\}/g,
1717
(_, key) => ((v) => v ? `:${v}` : "")(process.env[key]),
1818
)
1919
.replaceAll(/\$\{([a-zA-Z0-9_]+)\}/g, (_, key) => process.env[key] ?? "")
2020
.replaceAll(/\$([a-zA-Z0-9_]+)/g, (_, key) => process.env[key] ?? "");
2121
return value;
2222
};
2323

24+
let found = false;
25+
2426
readInterface.on("line", (line) => {
27+
if (!found) found = line == "set -a";
28+
if (!found) return;
2529
const match = line.match(/^([^=]+)=(.*)$/);
2630
if (match) {
2731
const [_, key, value_] = match;

action.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ description:
44

55
inputs:
66
path:
7+
description: path that should be evaluated by `dev`
78
required: false
89

910
runs:

0 commit comments

Comments
 (0)