4.9.0 #29
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Publish Gem | |
| on: | |
| release: | |
| types: [published] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v1 | |
| - name: Setup Git Credentials | |
| run: | | |
| git config --global user.email "support@freeclimb.com" | |
| git config --global user.name "FreeClimb" | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@359bebbc29cbe6c87da6bc9ea3bc930432750108 | |
| with: | |
| ruby-version: '3.1' | |
| - name: Install dependencies | |
| run: bundle install | |
| - name: Build | |
| run: bundle exec rake build | |
| - name: Release Gem | |
| run: | | |
| mkdir -p $HOME/.gem | |
| touch $HOME/.gem/credentials | |
| chmod 0600 $HOME/.gem/credentials | |
| printf -- "---\n:rubygems_api_key: ${RUBYGEMS_API_KEY}\n" > $HOME/.gem/credentials | |
| gem push pkg/*.gem | |
| env: | |
| GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} | |
| RUBYGEMS_API_KEY: ${{secrets.RUBYGEMS_API_KEY}} |