Skip to content

Commit

Permalink
Merge f09fe11 into 12bf9b7
Browse files Browse the repository at this point in the history
  • Loading branch information
meineerde committed Jul 17, 2020
2 parents 12bf9b7 + f09fe11 commit 7a1dca1
Show file tree
Hide file tree
Showing 3 changed files with 125 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/config/rubocop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# Description: The name of the check that will be created.
# Valid Options: A reasonably sized string.
# Default: 'Rubocop Action'
check_name: 'Rubocop Results'

# Description: Versions required to run your RuboCop checks.
# Valid options: RuboCop and any RuboCop extension, by default the latest gem version will be used. You can explicitly state that
# (not required) or use a version number, like '1.5.1'.
# Default:
# versions:
# - rubocop: 'latest'
versions:
- rubocop
- rubocop-performance
- rubocop-rspec

# Description: Rubocop configuration file path relative to the workspace.
# Valid options: A valid file path inside of the workspace.
# Default: nil
# Note: This does not need to be filled out for Rubocop to still find your config.
# Resource: https://rubocop.readthedocs.io/en/stable/configuration/
rubocop_config_path: '.rubocop.yml'

# Run all cops enabled by configuration except this list.
# Valid options: list of valid cop(s) and/or departments.
# Default: nil
# Resource: https://rubocop.readthedocs.io/en/stable/cops/
rubocop_excluded_cops: []

# Minimum severity for exit with error code
# Valid options: 'refactor', 'convention', 'warning', 'error', or 'fatal'.
# Default: 'warning'
# Resource: https://rubocop.readthedocs.io/en/stable/configuration/#severity
rubocop_fail_level: 'warning'

# Instead of installing gems from rubygems, we can run `bundle install` on your project,
# you would need to do this if you are using something like 'rubocop-github' or if you don't
# want to list out dependencies with the `versions` key.
# Valid options: true || false
# Default: false
bundle: false

# The scope of code that Rubocop should lint. Use this if you only want to lint changed files. If this is not set
# or not equal to 'modified', Rubocop is run against the entire codebase. Note that this will not work on the master branch.
# Valid options: 'modified'
# Default: nil
# check_scope: 'modified'
24 changes: 24 additions & 0 deletions .github/workflows/linter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: linter

on:
pull_request:
push:
tags-ignore:
- '*'
paths-ignore:
- README.md
- CHANGELOG.md

jobs:
robucop:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2

- name: Rubocop
uses: andrewmcodes/rubocop-linter-action@v3.2.0
with:
action_config_path: '.github/config/rubocop.yml'
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
54 changes: 54 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
name: rspec

on:
pull_request:
push:
tags-ignore:
- '*'
paths-ignore:
- README.md
- CHANGELOG.md
schedule:
- cron: '0 7 * * SUN'

jobs:
rspec:
strategy:
fail-fast: false
matrix:
os: [ubuntu, macos, windows]
ruby:
- '2.7'
- '2.6'
- '2.5'
- '2.4'
- '2.3'
- '2.2'
- '2.1'
- head

- jruby-9.1
- jruby-9.2
- jruby-head

- truffleruby
- truffleruby-head

include:
- ruby: '2.7'
env:
COVERAGE: '1'

runs-on: ${{ matrix.os }}-latest
continue-on-error: ${{ endsWith(matrix.ruby, 'head') }}

steps:
- uses: actions/checkout@v2

- uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
bundler-cache: true

- name: Run rspec
run: bundle exec rspec

0 comments on commit 7a1dca1

Please sign in to comment.