Skip to content

Commit

Permalink
Update GitHub Actions workflow and gemspec for Ruby compatibility
Browse files Browse the repository at this point in the history
  • Loading branch information
ydah committed Feb 1, 2025
1 parent fe2986d commit e4792a1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 10 deletions.
20 changes: 11 additions & 9 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,24 +4,26 @@ on:
push:
branches:
- main

pull_request:

jobs:
build:
runs-on: ubuntu-latest
name: Ruby ${{ matrix.ruby }}
ruby-versions:
uses: ruby/actions/.github/workflows/ruby_versions.yml@master
with:
engine: cruby
min_version: 2.5
test:
needs: ruby-versions
runs-on: ubuntu-22.04
strategy:
fail-fast: false
matrix:
ruby:
- '3.4'

ruby: ${{ fromJson(needs.ruby-versions.outputs.versions) }}s
steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true
- name: Run the default task
run: bundle exec rake
- run: exe/railroad_diagrams --format=svg
2 changes: 1 addition & 1 deletion railroad_diagrams.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Gem::Specification.new do |spec|
spec.description = 'Generate SVG railroad syntax diagrams, like on JSON.org.'
spec.homepage = "https://github.com/ydah/railroad_diagrams"
spec.license = 'MIT'
spec.required_ruby_version = '>= 3.1.0'
spec.required_ruby_version = '>= 2.5.0'

spec.metadata["homepage_uri"] = spec.homepage
spec.metadata["source_code_uri"] = spec.homepage
Expand Down

0 comments on commit e4792a1

Please sign in to comment.