mirror of
https://code.forgejo.org/forgejo/runner.git
synced 2025-08-26 18:20:59 +00:00
refuses to use the default for an nodejs input when an composite action has an input with the same name. clean cherry-pick (except for trivial context conflict) of two related pull requests - https://github.com/nektos/act/pull/2348 - https://github.com/nektos/act/pull/2473 <!--start release-notes-assistant--> <!--URL:https://code.forgejo.org/forgejo/runner--> - bug fixes - [PR](https://code.forgejo.org/forgejo/runner/pulls/818): <!--number 818 --><!--line 0 --><!--description Zml4OiBjb21wb3NpdGUgYWN0aW9uIGlucHV0IHBvbGx1dGlvbg==-->fix: composite action input pollution<!--description--> <!--end release-notes-assistant--> Co-authored-by: ChristopherHX <christopher.homberger@web.de> Reviewed-on: https://code.forgejo.org/forgejo/runner/pulls/818 Reviewed-by: Gusted <gusted@noreply.code.forgejo.org> Co-authored-by: Earl Warren <contact@earl-warren.org> Co-committed-by: Earl Warren <contact@earl-warren.org>
14 lines
No EOL
391 B
JavaScript
14 lines
No EOL
391 B
JavaScript
const { appendFileSync } = require('fs');
|
|
const step = process.env['INPUT_STEP'];
|
|
appendFileSync(process.env['GITHUB_ENV'], `TEST=${step}-post`, { encoding:'utf-8' })
|
|
|
|
var cache = process.env['INPUT_CACHE']
|
|
try {
|
|
var cache = JSON.parse(cache)
|
|
} catch {
|
|
|
|
}
|
|
if(typeof cache !== 'boolean') {
|
|
console.log("Input Polluted boolean true/false expected, got " + cache)
|
|
process.exit(1);
|
|
} |