Make vars available as action outputs

This commit is contained in:
Nathan Allen 2023-05-05 12:45:11 -04:00
parent d4b9b8ff72
commit 639e5e2bb8

View file

@ -37,6 +37,8 @@ try {
if (matches && matches.length > 0) { if (matches && matches.length > 0) {
// This will also set process.env accordingly, so changes take effect for this script // This will also set process.env accordingly, so changes take effect for this script
core.exportVariable(matches[1], matches[2]) core.exportVariable(matches[1], matches[2])
// Set the output variable for the action
core.setOutput(matches[1], matches[2])
console.log(`${matches[1]}=${matches[2]}`); console.log(`${matches[1]}=${matches[2]}`);
} }
}); });