From 7bc1f944009b76aae6bbbdbf438f884a44a176a4 Mon Sep 17 00:00:00 2001 From: jonathan schatz Date: Sun, 10 Dec 2023 17:55:48 -0800 Subject: [PATCH] add rubocop --- .github/workflows/ruby.yml | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/.github/workflows/ruby.yml b/.github/workflows/ruby.yml index 88a4653..5836f76 100644 --- a/.github/workflows/ruby.yml +++ b/.github/workflows/ruby.yml @@ -14,7 +14,6 @@ on: jobs: test: runs-on: ubuntu-latest - steps: - uses: actions/checkout@v4 - uses: ruby/setup-ruby@v1 @@ -35,3 +34,22 @@ jobs: bundle exec appraisal install - name: Run tests run: bundle exec appraisal rake + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: ruby/setup-ruby@v1 + with: + ruby-version: "3.2" # Not needed with a .ruby-version file + - uses: actions/cache@v3 + with: + path: vendor/bundle + key: ${{ runner.os }}-gems-${{ hashFiles('**/cloudflare-rails.gemspec') }} + restore-keys: | + ${{ runner.os }}-gems- + - name: Bundle install + run: | + bundle config path vendor/bundle + bundle install --jobs 4 --retry 3 + - name: Rubocop + run: rubocop