A Github action to run pronto.
This action support the following pronto runners.
- pronto-brakeman
- pronto-eslint_npm
- pronto-rails_best_practices
- pronto-rubocop
- pronto-scss
- pronto-slim_lint
- pronto-sorbet
This action support the following rubocop extentions.
- rubocop-i18n
- rubocop-md
- rubocop-minitest
- rubocop-performance
- rubocop-rails
- rubocop-rake
- rubocop-require_tools
- rubocop-rspec
- rubocop-sequel
- rubocop-thread_safety
Create Github workflow definition yaml file in .github/workflows directory of your repository.
This action can be configured by the following input parameters.
| name | require | default | description |
|---|---|---|---|
| github_token | true | -- | |
| commit | false | origin/master |
Commit for the diff. |
| runner | false | rubocop |
Run only the passed runners. |
| formatters | false | github_status github_pr |
Pick output formatters. |
| path | false | '.' |
Relative path to check. |
see Pronto usage.
The followoing yaml is a simplest workflow difinition of using pronto-action.
name: Pronto
on:
pull_request:
types: [opened, synchronize]
jobs:
pronto:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- uses: HeRoMo/pronto-action@v1.5.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
commit: origin/mainBy using eslint_npm runner, you can check your code by eslint.
To use eslint_npm, setup Node.js and run yarn install(or npm install) before using pronto-action.
The following yaml define a workflow use eslint_npm.
name: Pronto
on:
pull_request:
types: [opened, synchronize]
jobs:
eslint_npm:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Setup Node.js
uses: actions/setup-node@v1
with:
node-version: '12.18.x'
- name: yarn install
run: yarn install
- name: pronto run
uses: HeRoMo/pronto-action@v1.5.0
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
runner: eslint_npmIf does not work successfully, configure elint_npm with .pronto_eslint_npm.yml file. see Configuration of ESLintNPM