Bump http from 5.1.1 to 5.2.0 #295
This file contains 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: Continuous Integration | |
on: | |
push: | |
branches: | |
- '**' | |
tags: | |
- '**' | |
schedule: | |
- cron: '0 7 * * 1' # Run every monday at 07:00 UTC | |
jobs: | |
build: | |
name: Continuous Integration | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
ruby: [ "3.0", "3.1", "3.2", "3.3" ] | |
container: | |
image: ruby:${{ matrix.ruby }}-alpine | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install dependencies | |
run: | | |
apk add build-base cmake git tar | |
- name: Cache Gems | |
uses: actions/[email protected] | |
with: | |
path: vendor/bundle | |
key: ${{ runner.os }}-${{ matrix.ruby }}-gem-${{ hashFiles('**/Gemfile.lock') }} | |
restore-keys: | | |
${{ runner.os }}-${{ matrix.ruby }}-gem- | |
- name: Install Gems | |
run: | | |
gem install bundler | |
bundle config path vendor/bundle | |
bundle install --jobs 4 --retry 3 | |
- name: Test | |
run: | | |
if [[ "$EVENT_NAME" == "schedule" ]]; then | |
bundle exec rspec --format progress --tag integration | |
else | |
bundle exec rspec --profile 10 --format progress | |
fi | |
- name: Lint | |
run: bundle exec rubocop --config .rubocop.yml --parallel --display-cop-names | |
release: | |
name: Release application | |
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v') | |
runs-on: ubuntu-latest | |
needs: build | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set version | |
run: | | |
echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV | |
- name: Publish to RubyGems | |
run: | | |
mkdir -p ~/.gem | |
touch ~/.gem/credentials | |
chmod 0600 ~/.gem/credentials | |
printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > ~/.gem/credentials | |
gem build *.gemspec | |
gem push *.gem | |
env: | |
GEM_HOST_API_KEY: ${{secrets.RUBYGEMS_API_KEY}} | |
- name: Create Github Release | |
uses: actions/create-release@v1 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: ${{ github.ref }} | |
body: | | |
Gem ${{ github.event.repository.name }} ${{ env.VERSION }} was released |