This commit is contained in:
@@ -1,21 +1,32 @@
|
|||||||
name: CI
|
name: CI
|
||||||
|
|
||||||
on: [push, pull_request]
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
pull_request:
|
||||||
|
branches:
|
||||||
|
- main
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
test:
|
ci:
|
||||||
runs-on: ubuntu-latest
|
runs-on: gitea
|
||||||
steps:
|
steps:
|
||||||
- run: |
|
- name: Checkout
|
||||||
git clone --depth 1 https://${{ gitea.server }}/${{ gitea.repository }} .
|
run: |
|
||||||
git fetch --depth=1 origin ${{ gitea.sha }}
|
git clone https://${{ gitea.server }}/${{ gitea.repository }} .
|
||||||
git checkout ${{ gitea.sha }}
|
git checkout ${{ gitea.sha }}
|
||||||
|
|
||||||
- run: |
|
- name: Install Python deps
|
||||||
|
run: |
|
||||||
python3 -m pip install --upgrade pip
|
python3 -m pip install --upgrade pip
|
||||||
python3 -m pip install pytest ruff
|
python3 -m pip install pytest ruff -q
|
||||||
python3 -m pip install -e ".[dev]"
|
python3 -m pip install -e ".[dev]" -q
|
||||||
|
|
||||||
- run: python3 -m pytest tests/ -v --tb=short
|
- name: Test
|
||||||
|
run: |
|
||||||
|
python3 -m pytest tests/ -v --tb=short || exit 1
|
||||||
|
|
||||||
- run: python3 -m ruff check i18n_key_sync/ tests/
|
- name: Lint
|
||||||
|
run: |
|
||||||
|
python3 -m ruff check i18n_key_sync/ tests/ || exit 1
|
||||||
|
|||||||
Reference in New Issue
Block a user