DEV: Update publish-rubygems-action to v2 (#27)

DEV: Update publish-rubygems-action to v2 (#27)

diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index f6bc853..2dd0267 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -41,7 +41,7 @@ jobs:
         run: bundle exec rspec
 
   publish:
-    if: contains(github.ref, 'refs/tags/v')
+    if: github.event_name == 'push' && github.ref == 'refs/heads/main'
     needs: build
     runs-on: ubuntu-latest
 
@@ -49,6 +49,8 @@ jobs:
       - uses: actions/checkout@v2
 
       - name: Release Gem
-        uses: discourse/publish-rubygems-action@main
+        uses: discourse/publish-rubygems-action@v2
         env:
-          RUBYGEMS_API_KEY: ${{secrets.RUBYGEMS_API_KEY}}
+          RUBYGEMS_API_KEY: ${{ secrets.RUBYGEMS_API_KEY }}
+          GIT_EMAIL: team@discourse.org
+          GIT_NAME: discoursebot

GitHub sha: 54547b7cb0266aebad82ea00efb4cbd5b7767bfb

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