forked from Azure-Samples/python-openai-demos
-
Notifications
You must be signed in to change notification settings - Fork 0
29 lines (27 loc) · 752 Bytes
/
python.yaml
File metadata and controls
29 lines (27 loc) · 752 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
name: Check example files are linted and formatted
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- name: Set up Python 3
uses: actions/setup-python@v6
with:
python-version: "3.11"
- name: Install uv
uses: astral-sh/setup-uv@v7
- name: Set up virtual environment and install dependencies
run: |
uv venv .venv
uv pip install -r requirements-dev.txt
- name: Lint with ruff
run: |
uv run ruff check .
- name: Check formatting with black
run: |
uv run black . --check --verbose