core.setFailed(`"${strategy}" is not a recognized tagging strategy. Choose from: 'package' (package.json), 'docker' (uses Dockerfile), or 'regex' (JS-based RegExp).`)
return
}
core.setOutput('version',version)
core.debug(` Detected version ${version}`)
// Configure a tag using the identified version
consttag=newTag(
core.getInput('tag_prefix',{required:false}),
version,
core.getInput('tag_suffix',{required:false})
)
// Check for existance of tag and abort (short circuit) if it already exists.
if(awaittag.exists()){
core.warning(`"${tag.name}" tag already exists.`+os.EOL)
core.setOutput('tagname','')
return
}
// The tag setter will autocorrect the message if necessary.