Add outputs gem_version and new_version (#1)

Add outputs gem_version and new_version (#1)

Allows chaining this action, for example to run a deployment if new_version is "true" using gem_version

diff --git a/entrypoint.sh b/entrypoint.sh
index b6d4700..ccea1a6 100755
--- a/entrypoint.sh
+++ b/entrypoint.sh
@@ -13,11 +13,15 @@ chmod 0600 ~/.gem/credentials
 set -x
 
 gem_version=$(ruby -r rubygems -e "puts Gem::Specification::load('$(ls *.gemspec)').version")
+echo "::set-output name=gem_version::$gem_version"
 
 if git fetch origin "refs/tags/v$gem_version" >/dev/null 2>&1
 then
   echo "Tag 'v$gem_version' already exists"
+  echo "::set-output name=new_version::false"
 else
+  echo "::set-output name=new_version::true"
+
   git config user.email "${GIT_EMAIL:-automated@example.com}"
   git config user.name "${GIT_NAME:-Automated Release}"
 

GitHub sha: 43894a7e20ed4bf1186240b47a2b9fac3aeb1cb9

This commit appears in #2 which was approved by davidtaylorhq. It was merged by CvX.