Skip to content
You're viewing an older version of this GitHub Action. Do you want to see the latest version instead?
check-square

GitHub Action

arduino/arduino-lint-action

v1.0.1

arduino/arduino-lint-action

check-square

arduino/arduino-lint-action

Check Arduino projects for problems

Installation

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

              

- name: arduino/arduino-lint-action

uses: arduino/arduino-lint-action@v1.0.1

Learn more about this action in arduino/arduino-lint-action

Choose a version

arduino/arduino-lint-action

Tests Status Integration Tests Status Check Packaging status Check TypeScript Configuration status Check npm status Spellcheck Status

GitHub Actions action that uses Arduino Lint to check for problems with Arduino projects:

  • Libraries
  • Sketches
  • Boards platforms
  • Boards Manager package indexes

Table of contents

Inputs

path

Path containing Arduino project(s).

Default: ./

version

The version of Arduino Lint to use. Can be an exact version (e.g., 1.0.0) or a version range (e.g., 1.x).

Default: 1.x

compliance

Configure how strict the tool is about which checks are considered errors vs warnings if they don't pass.

Supported values

  • strict - enforces best practices, above and beyond the minimum requirements for specification compliance. Use this setting to ensure the best experience for the users of the project.
  • specification - enforces compliance with the official Arduino project specifications.
  • permissive - will cause the checks to fail only when severe problems are found. Although a project that passes at the permissive setting will work with the current Arduino development software versions, it may not be fully specification-compliant, risking incompatibility or a poor experience for the users.

Default: specification

library-manager

Configure the checks for libraries in the Arduino Library Manager index.

Supported values

  • submit - Also run additional checks required to pass before a library is accepted for inclusion in the index.
  • update- Also run additional checks required to pass before new releases of a library already in the index are accepted.
  • false - Don't run any Library Manager-specific checks.

Default: submit for libraries, false for other project types

project-type

Configures which types of projects to check, along with their subprojects.

Supported values

  • sketch
  • library
  • platform - boards platform
  • package-index - Boards Manager package index
  • all - Run checks on any type of project that is detected

Default: all

recursive

Set to true to search path recursively for Arduino projects to check.

Default: false

report-file

Save a JSON formatted report on the checks to this file.

verbose

Set to true to show more information in the log about the checks being run.

Default: false

token

GitHub access token used to get information from the GitHub API.

Default: GITHUB_TOKEN

Usage

The minimal workflow to run the default checks on the projects in the repository:

on: [push, pull_request]
jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: arduino/arduino-lint-action@v1

A more complex workflow which uses inputs to configure the action for Library Manager "update" mode and strict compliance:

on: [push, pull_request]
jobs:
  lint:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: arduino/arduino-lint-action@v1
        with:
          library-manager: update
          compliance: strict

Contributing

To report bugs or make feature requests, please submit an issue: https://github.com/arduino/arduino-lint-action/issues

Pull requests are welcome! Please see the contribution guidelines for information.