Compare commits

...

2 Commits

Author SHA1 Message Date
peaceiris
0f98ab44f5 feat: Add print_info for tag options 2020-01-13 00:53:19 +09:00
peaceiris
58f69047b6 feat: Add tagName and tagMessage options
Close #76
2020-01-13 00:34:43 +09:00
2 changed files with 17 additions and 0 deletions

View File

@ -29,3 +29,9 @@ inputs:
commitMessage: commitMessage:
description: 'Set custom commit message' description: 'Set custom commit message'
required: false required: false
tagName:
description: 'Set tag name'
required: false
tagMessage:
description: 'Set tag message'
required: false

View File

@ -142,4 +142,15 @@ else
git push origin "${remote_branch}" git push origin "${remote_branch}"
fi fi
if [[ -n "${INPUT_TAGNAME}" ]]; then
print_info "Tag name: ${INPUT_TAGNAME}"
if [[ -n "${INPUT_TAGMESSAGE}" ]]; then
print_info "Tag message: ${INPUT_TAGMESSAGE}"
git tag "${INPUT_TAGNAME}" -m "${INPUT_TAGMESSAGE}"
else
git tag "${INPUT_TAGNAME}"
fi
git push origin "${INPUT_TAGNAME}"
fi
print_info "${GITHUB_SHA} was successfully deployed" print_info "${GITHUB_SHA} was successfully deployed"