fix(tag): fix tag logs

It seems like simple-git handlers don't work for custom git tag commands
Promises still work, we'll try to use them then
This commit is contained in:
Federico Grandi
2020-12-12 17:01:09 +01:00
parent cac5e6ba5b
commit d8573f888f
2 changed files with 11 additions and 5 deletions

File diff suppressed because one or more lines are too long

View File

@@ -86,10 +86,16 @@ console.log(`Running in ${baseDir}`)
if (getInput('tag')) {
info('> Tagging commit...')
await git.tag(getInput('tag').split(' '), (err, data?) => {
if (data) setOutput('tagged', 'true')
return log(err, data)
})
await git
.tag(getInput('tag').split(' '), (err, data?) => {
if (data) setOutput('tagged', 'true')
return log(err, data)
})
.then((data) => {
setOutput('tagged', 'true')
return log(null, data)
})
.catch((err) => log(err))
} else info('> No tag info provided.')
if (getInput('push')) {