Skip to content

Commit

Permalink
Configuring workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
jcagarcia committed Nov 3, 2023
1 parent 3dd4f21 commit e26ee23
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions .github/workflows/gem-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,13 @@ jobs:
echo "::set-output name=version::$VERSION"
shell: bash

- name: Check if Gem Version Exists in ruby gems
id: check-exists
run: |
gem fetch grape-idempotency -v ${{ steps.get-version.outputs.version }}
if [ $? -eq 0 ]; then
echo "Gem version already exists on RubyGems. Skipping the push to RubyGems."
exit 0
fi
shell: bash

- name: Publish to RubyGems
run: |
gem fetch grape-idempotency -v ${{ steps.get-version.outputs.version }}
if [ $? -eq 0 ]; then
echo "Gem version already exists on RubyGems. Skipping the push to RubyGems."
exit 0
fi
mkdir -p $HOME/.gem
touch $HOME/.gem/credentials
chmod 0600 $HOME/.gem/credentials
Expand Down

0 comments on commit e26ee23

Please sign in to comment.