Fix credits URLs and bump version to 0.1.1 #5
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: CI | |
| on: | |
| workflow_dispatch: {} | |
| push: | |
| branches: | |
| - main | |
| tags: | |
| - v[0-9]+.[0-9]+.[0-9]+* | |
| pull_request: | |
| branches: | |
| - main | |
| jobs: | |
| build: | |
| name: Build | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: "3.3" | |
| bundler-cache: true | |
| - name: Lint | |
| run: bundle exec rubocop | |
| - name: Build | |
| run: gem build elia_ruby.gemspec | |
| - name: Upload Artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: gems | |
| path: "*.gem" | |
| test: | |
| name: Test (${{ matrix.ruby-version }}) | |
| runs-on: ubuntu-22.04 | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| ruby-version: ["2.7", "3.0", "3.1", "3.2", "3.3", "3.4", jruby-head, truffleruby-head] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Ruby ${{ matrix.ruby-version }} | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: ${{ matrix.ruby-version }} | |
| bundler-cache: true | |
| - name: Run tests | |
| run: bundle exec rspec | |
| publish: | |
| name: Publish | |
| if: >- | |
| ((github.event_name == 'workflow_dispatch') || (github.event_name == 'push')) && | |
| startsWith(github.ref, 'refs/tags/v') | |
| needs: [build, test] | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - name: Download all workflow run artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: gems | |
| path: gems | |
| - name: Set up Ruby | |
| uses: ruby/setup-ruby@v1 | |
| with: | |
| ruby-version: "3.3" | |
| - name: Publish gems to RubyGems | |
| run: gem push gems/*.gem | |
| env: | |
| GEM_HOST_API_KEY: ${{ secrets.GEM_HOST_API_KEY }} |