No description
  • Shell 77.1%
  • Dockerfile 14%
  • Python 8.9%
Find a file
Ricardo Baltazar Chaves 5b63e847e7
Merge pull request #19 from vapier/master
update to actions/checkout@v4
2024-01-04 08:32:02 -03:00
.github/workflows update to actions/checkout@v4 2024-01-02 11:44:29 -05:00
tests fixed lint 2019-12-01 12:14:09 -03:00
.gitignore Docker image updated 2020-08-08 11:44:51 -03:00
action.yml added icon and color 2020-08-22 22:49:36 -03:00
CODE_OF_CONDUCT.md Create CODE_OF_CONDUCT.md 2020-08-22 22:58:09 -03:00
CONTRIBUTING.md added CONTRIBUTING.md 2020-08-22 22:53:13 -03:00
Dockerfile update docker image (#14) 2021-04-28 20:33:41 -03:00
entrypoint.sh updated isort for version 5 and removed -rc 2020-08-08 18:02:00 -03:00
LICENSE update 2019-12-01 12:35:20 -03:00
README.md update to actions/checkout@v4 2024-01-02 11:44:29 -05:00

python-lint

All lints status

About

This action must be used for aplication the bids:

Usage

See action.yml

Basic:

steps:
  - uses: actions/checkout@v4
  - uses: ricardochaves/python-lint@v1.4.0

Options:

steps:
  - uses: actions/checkout@v4
  - uses: ricardochaves/python-lint@v1.4.0
    with:
      python-root-list: "python_alelo tests"
      use-pylint: false
      use-pycodestyle: false
      use-flake8: false
      use-black: false
      use-mypy: false
      use-isort: false
      extra-pylint-options: ""
      extra-pycodestyle-options: ""
      extra-flake8-options: ""
      extra-black-options: ""
      extra-mypy-options: ""
      extra-isort-options: ""

Command build logic list:

pylint $(extra-pylint-options) $(python-root-list)

pycodestyle $(extra-pycodestyle-options) $(python-root-list)

flake8 $(extra-flake8-options) $(python-root-list)

black --check $(extra-black-options) $(python-root-list)

mypy $(extra-mypy-options) $(python-root-list)

isort $(extra-isort-options) $(python-root-list) -c --diff

Versions used

To identify the version used you must consult the CHANGELOG.md of the image used in our Dockerfile.

Test locally

Use act to test the action locally. Unfortunately it still doesn't work on all OSs, if you can't use it try the solution below.

Some libs may behave differently between OSs. That's why this action runs on a docker image. This makes it possible for us to test some things locally.

Using docker compose, add the following service

  test-lint:
    image: ricardobchaves6/python-lint-image:1.3.0
    working_dir: /app
    volumes:
      - .:/app
    command: ["mypy", "."]

Use the commands described in the section above. Choose the version of the image equivalent to the version of the action.

License

The scripts and documentation in this project are released under the MIT License

Contributions

Contributions are welcome! See CONTRIBUTING.md