Skip to content

lpenz/omnilint

Use this GitHub Action with your project

Add this Action to an existing workflow or create a new one.

View on Marketplace
main
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
bin
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

marketplace CI github docker

omnilint

TL;DR

Use omnilint as a github action with a workflow file like the following:

name: CI
on: push
jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v2
      - uses: docker://lpenz/omnilint:0.5.1

Another option is using this repository's callable workflow:

name: CI
on: push
jobs:
  omnilint:
    uses: lpenz/ghworkflow-rust/.github/workflows/rust.yml@v0.5.1

Or add the following to your .travis.yml to get a job that performs static analysis on the files of your repository:

jobs:
  include:
    - name: omnilint
      language: generic
      install: docker pull lpenz/omnilint
      script: docker run --rm -u "$UID" -v "$PWD:$PWD" -w "$PWD" lpenz/omnilint

What is omnilint

omnilint is a container-based tool that provides a unified interface for the static analysis of any file, using the appropriate tool.

File                    Linter
.c  \                  / cppcheck
.sh  -    omnilint    -  shelcheck
.py /        |         \ pyflakes
      gcc-like output
        json output

omnilint is specially useful when combined with CI tools like travis, jenkins, etc.

Installation and local usage

Requirements:

  • docker

The easier way to install omnilint is by pulling the container from docker hub:

docker pull lpenz/omnilint

Using omnilint is a matter of starting the container with the directory with the files to be analyzed mapped:

docker run --rm -u "$UID" -v "$PWD:$PWD" -w "$PWD" omnilint

You can also simply call the script bin/omnilint-docker-run that is present in the repository.