Skip to content

Commit

Permalink
Merge pull request #49 from kickstarter/fix-release
Browse files Browse the repository at this point in the history
fix release action
  • Loading branch information
amancevice authored Jan 8, 2024
2 parents 4dc598f + 72c93a5 commit bf9a238
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
12 changes: 9 additions & 3 deletions .github/workflows/test-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,14 @@ jobs:
- uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2"
- uses: kickstarter/actions/setup-rubygems@main
with:
api-key: ${{ secrets.RUBYGEMS_API_KEY }}
# The kickstarter/actions/setup-rubygems action is not available
# because this is a public repo
- run: |
mkdir -p ~/.gem
cat <<-YAML > ~/.gem/credentials
---
:rubygems_api_key: ${{ secrets.RUBYGEMS_API_KEY }}
YAML
chmod 0600 ~/.gem/credentials
- run: bundle install
- run: bundle exec rake gem:push
8 changes: 8 additions & 0 deletions Taskfile.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,14 @@ tasks:
- bundle exec rake spec

release:
desc: Publish gem with GitHub
vars:
VERSION:
sh: bundle exec ruby -r replica_pools -e 'puts "v#{ReplicaPools::VERSION}"'
cmds:
- gh release create {{.VERSION}} --generate-notes

release:manual:
desc: Release gem
cmds:
- bundle exec rake release
Expand Down

0 comments on commit bf9a238

Please sign in to comment.