2024-01-03 23:43:35 +01:00
|
|
|
name: Python CI
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: ['main']
|
|
|
|
pull_request:
|
|
|
|
jobs:
|
|
|
|
build:
|
2024-01-05 02:18:20 +01:00
|
|
|
name: 'Format Backend'
|
2024-01-03 23:43:35 +01:00
|
|
|
env:
|
|
|
|
PUBLIC_API_BASE_URL: ''
|
2024-03-19 10:42:01 +01:00
|
|
|
RUNNER_TOOL_CACHE: /toolcache
|
2024-01-03 23:43:35 +01:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
node-version:
|
|
|
|
- latest
|
2024-03-19 10:42:01 +01:00
|
|
|
python-version: [ '2.x', '3.x' ]
|
2024-01-03 23:43:35 +01:00
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Use Python
|
2024-03-19 10:42:01 +01:00
|
|
|
uses: actions/setup-python@v2
|
|
|
|
with:
|
|
|
|
python-version: ${{ matrix.python-version }}
|
2024-01-03 23:43:35 +01:00
|
|
|
- name: Use Bun
|
|
|
|
uses: oven-sh/setup-bun@v1
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
python -m pip install --upgrade pip
|
|
|
|
pip install yapf
|
|
|
|
- name: Format backend
|
|
|
|
run: bun run format:backend
|