Commit 1c85b4e2 authored by Bart Kamphorst's avatar Bart Kamphorst Committed by Ruben ten Hove
Browse files

feat: pycln job for flagging unused imports

parent 77b46cf6
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
---
include:
  - local: python/mypy.yml
  - local: python/pycln.yml
  - local: python/pylint.yml
  - local: python/pytest.yml

python/pycln.yml

0 → 100644
+19 −0
Original line number Diff line number Diff line
---
# pycln checks for unused imports
# https://pypi.org/project/pycln/
include:
  - local: python/generic.yml

variables:
  PYCLN_DEFAULT_ARGS: --check --all
  PYCLN_EXTRA_ARGS: ""

python:pycln:
  extends: .python:pre
  variables:
    JOB_PACKAGE: pycln
  script:
    - !reference [".python:pre", script]
    - pycln ${PYCLN_DEFAULT_ARGS} ${PYCLN_EXTRA_ARGS} . || (echo "[!] Problems
      found. Run 'pycln .' in your source directory to fix these." && exit 1)
  needs: []