GithubHelp home page GithubHelp logo

Comments (9)

bolah2009 avatar bolah2009 commented on August 16, 2024 1

@euqueme @uryelah Can you please check this issue?

from linters-config.

uryelah avatar uryelah commented on August 16, 2024

@euqueme @uryelah Can you please check this issue?

@bolah2009 We could try a matrix strategy to accept multiple versions of ruby. I'll test this out.

name: Ruby CI

on:
  push:
    branches: [ $default-branch ]
  pull_request:
    branches: [ $default-branch ]

jobs:
  test:

    runs-on: ubuntu-latest

    strategy:
      matrix:
        ruby-version: [2.7.x, 2.6.x, 2.5.x]

    steps:
    - uses: actions/checkout@v2
    - name: Set up Ruby ${{ matrix.ruby-version }}
      uses: ruby/setup-ruby@v1
      with:
        ruby-version: ${{ matrix.ruby-version }}
    - name: Install dependencies
      run: bundle install
    - name: Run tests
      run: bundle exec rake

from linters-config.

uryelah avatar uryelah commented on August 16, 2024

@IjayAbby Coudl you send a screenshot of the error?
Did you have a .ruby-version file in the project?
Did both actions fail or just one of them, Rubocop or Rspec.

from linters-config.

uryelah avatar uryelah commented on August 16, 2024

It seems that Rubocop runs ok on projects built with ruby version 3 unless there's a .ruby-version file

from linters-config.

bolah2009 avatar bolah2009 commented on August 16, 2024

@uryelah if we update the current version of robocop, would that solve this issue?

from linters-config.

uryelah avatar uryelah commented on August 16, 2024

@bolah2009 I'm double checking this but I really think just asking students to not commit .ruby-version files would be enough.

from linters-config.

uryelah avatar uryelah commented on August 16, 2024

@bolah2009
We could change the rubocop version to 1.9 and accept any ruby version above 2.6.x
What do you think? That seems to work properly.

Ex:

name: Linters

on: pull_request

jobs:
  rubocop:
    name: Rubocop
    runs-on: ubuntu-18.04
    
    steps:
      - uses: actions/checkout@v2
      - uses: actions/setup-ruby@v1
        with:
          ruby-version: ">=2.6.x"
      - name: Setup Rubocop
        run: |
          gem install --no-document rubocop:'~>1.9.0' # https://docs.rubocop.org/en/stable/installation/
          [ -f .rubocop.yml ] || wget https://raw.githubusercontent.com/microverseinc/linters-config/master/ruby/.rubocop.yml
      - name: Rubocop Report
        run: rubocop --color

from linters-config.

uryelah avatar uryelah commented on August 16, 2024

@bolah2009 PR #126 created to add fix for 3.0.0 compatibility.
Please check this when you can.
CC @euqueme

from linters-config.

bolah2009 avatar bolah2009 commented on August 16, 2024

Merged in #126

from linters-config.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.