Skip to content

Legend

Legend #114

Workflow file for this run

# Workflow derived from https://github.com/r-lib/actions/tree/v2/examples
# Need help debugging build failures? Start at https://github.com/r-lib/actions#where-to-find-help
on:
push:
branches: [main, devel]
pull_request:
branches: [main, devel]
name: lint.yaml
permissions: read-all
jobs:
lint:
runs-on: ${{ matrix.config.os }}
name: Test linting ${{ matrix.config.os }} (${{ matrix.config.r }})
strategy:
fail-fast: false
matrix:
config:
- {os: ubuntu-latest, r: 4.4}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
R_KEEP_PKG_SOURCE: yes
steps:
- uses: actions/checkout@v4
- uses: r-lib/actions/setup-r@v2
with:
r-version: ${{ matrix.config.r }}
use-public-rspm: true
- uses: r-lib/actions/setup-r-dependencies@v2
with:
extra-packages: any::lintr, local::.
needs: lint
- name: Lint
run: |
lintr::lint_package(
linters = lintr::linters_with_defaults(
lintr::indentation_linter(indent = 4L),
lintr::cyclocomp_linter(complexity_limit = 50L)
)
)
shell: Rscript {0}
env:
LINTR_ERROR_ON_LINT: true