Skip to content
code

GitHub Action

Pronto Ruby

v4.1 Latest version

Pronto Ruby

code

Pronto Ruby

Run pronto code review runners on your commits and pull requests and get feedback as inline code annotations.

Installation

Copy and paste the following snippet into your .yml file.

              

- name: Pronto Ruby

uses: AdWerx/pronto-ruby@v4.1

Learn more about this action in AdWerx/pronto-ruby

Choose a version

Your all-in-one ruby Pronto runner.

This GitHub Action runs Pronto runners on your Ruby project diffs and reports back with a GitHub Check Run.

check runs

annotations

Runners

The docker image of this Action includes the following Pronto Runners:

  • brakeman
  • bundler_audit
  • eslint_npm
  • fasterer
  • flay
  • poper (removed—no support for pronto 0.11)
  • rails_best_practices
  • rails_schema
  • rails_data_schema (removed—no support for pronto 0.11)
  • reek
  • rubocop
  • scss
  • yamllint
  • stylelint

Inputs

name description default
runners Space-separated list of pronto runners to run. Must be the preinstalled runners from the list above. rubocop
target The git target pronto will diff against (-c) origin/master

Secrets

A GitHub token is available by default when using actions, but you must include it in the env map for this Action to use when creating a check run.

Be sure to include the ENV variable in your job step:

- uses: adwerx/pronto-ruby
  env:
    GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

That's it!

Configuration

Pronto can be configured via the .pronto.yml configuration file in your repo.

Example

With the defaults (only rubocop):

name: Pronto

on:
  - push
  - pull_request

jobs:
  run:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - run: git fetch origin master --depth=1
      - uses: adwerx/pronto-ruby@main # use a tag version here
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

With specific runners:

name: Pronto
# ...
      with:
        runners: >-
          rubocop rails_schema yamllint

With eslint_npm runner using locally installed eslint:

name: Pronto
# ...
    steps:
      - uses: actions/checkout@v2
        with:
          fetch-depth: 0
      - run: git fetch origin master --depth=1
      - uses: actions/setup-node@v1
      - run: yarn install --ignore-optional --ignore-scripts --frozen-lockfile --non-interactive
      - uses: adwerx/pronto-ruby@main # use a tag version here
        with:
          runners: eslint_npm # ...
        env:
          GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

Development / Contributions

See CONTRIBUTING.md