- change the default placeholder pattern from ${{}} to #{{}} as this will work for both config.json files and the yaml (${{}} is reserved for github actions syntax)

This commit is contained in:
Mike Penz
2023-08-31 19:14:23 +00:00
committed by GitHub
parent 677fedde3a
commit 695b32d625
19 changed files with 117 additions and 117 deletions
+1 -1
View File
@@ -153,7 +153,7 @@ function readConfiguration(filename: string): Configuration | undefined {
export function parseConfiguration(config: string): Configuration | undefined {
try {
// for compatiblity with the `yml` file we require to use `#{{}}` instead of `${{}}` - replace it here.
const configurationJSON: Configuration = JSON.parse(config.replace(/#{{/g, '${{'))
const configurationJSON: Configuration = JSON.parse(config.replace(/\${{/g, '#{{'))
return configurationJSON
} catch (error) {
core.info(`⚠️ Configuration provided, but it couldn't be parsed. Fallback to Defaults.`)