Skip to content
/ omnilint Public

Statically analyse any file with the appropriate tools

License

Notifications You must be signed in to change notification settings

lpenz/omnilint

Use this GitHub action with your project
Add this Action to an existing workflow or create a new one
View on Marketplace

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

58 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

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.2

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.2

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.