Debian Codegraph @

.github/workflows/lint.yml

raw
1 # Copyright (C) 2025 Siemens
2 #
3 # SPDX-License-Identifier: MIT
4
5 name: Lint Python Code
6
7 on:
8 push:
9 branches:
10 - main
11 pull_request:
12
13 jobs:
14 format:
15 runs-on: ubuntu-24.04
16
17 steps:
18 - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
19
20 - uses: actions/setup-python@5fda3b95a4ea91299a34e894583c3862153e4b97 # v7.0.0
21 with:
22 python-version: "3.x"
23
24 - name: Install dependencies
25 run: |
26 python -m pip install --upgrade pip
27 pip install black
28 - name: Check code formatting with black
29 run: |
30 black --check --diff $(git ls-files '*.py')