Skip to content

Commit

Permalink
Adding GitHub Actions (#2)
Browse files Browse the repository at this point in the history
* Adding GitHub Action

* moving dev dependencies to Gemfile
  • Loading branch information
eebbesen authored Oct 12, 2024
1 parent eb26bb3 commit 301e8c1
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 6 deletions.
31 changes: 31 additions & 0 deletions .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby

name: Ruby

on:
push:
workflow_dispatch:

permissions:
contents: read

jobs:
test:

runs-on: ubuntu-latest
strategy:
matrix:
ruby-version: ['3.0']

steps:
- uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby-version }}
bundler-cache: true # runs 'bundle install' and caches installed gems automatically
- name: Run tests
run: bundle exec rspec
- name: Run RuboCop
run: bundle exec rubocop
10 changes: 5 additions & 5 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ source 'https://rubygems.org'
# Specify your gem's dependencies in sheet_zoukas.gemspec
gemspec

gem 'rake', '~> 13.0'

gem 'rspec', '~> 3.0'

gem 'rubocop', '~> 1.21'
group :development, :test do
gem 'rake', '~> 13.0'
gem 'rspec', '~> 3.0'
gem 'rubocop', '~> 1.21'
end
2 changes: 1 addition & 1 deletion sheet_zoukas.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Gem::Specification.new do |spec|
spec.executables = spec.files.grep(%r{\Aexe/}) { |f| File.basename(f) }
spec.require_paths = ['lib']

spec.add_development_dependency 'rspec'
# spec.add_development_dependency 'rspec'

spec.metadata['rubygems_mfa_required'] = 'true'
end

0 comments on commit 301e8c1

Please sign in to comment.