CI for linting and testing
This commit is contained in:
42
.woodpecker/check.yml
Normal file
42
.woodpecker/check.yml
Normal file
@ -0,0 +1,42 @@
|
||||
kind: pipeline
|
||||
name: static-analysis
|
||||
|
||||
when:
|
||||
- event: push
|
||||
branch:
|
||||
- main
|
||||
- dev
|
||||
|
||||
variables:
|
||||
- &python_image "ghcr.io/astral-sh/uv:python3.13-bookworm-slim"
|
||||
- &uv_cache_dir "/root/.cache/uv"
|
||||
- &cache_key "uv-${CI_REPO_NAME}-${CI_COMMIT_BRANCH}"
|
||||
|
||||
steps:
|
||||
lint:
|
||||
image: *python_image
|
||||
environment:
|
||||
UV_CACHE_DIR: *uv_cache_dir
|
||||
UV_FROZEN: "1"
|
||||
commands:
|
||||
- uv sync --no-install-project
|
||||
- make lint
|
||||
volumes:
|
||||
- name: uv-cache
|
||||
path: *uv_cache_dir
|
||||
|
||||
test:
|
||||
image: *python_image
|
||||
environment:
|
||||
UV_CACHE_DIR: *uv_cache_dir
|
||||
UV_FROZEN: "1"
|
||||
commands:
|
||||
- uv sync --no-install-project
|
||||
- make test
|
||||
volumes:
|
||||
- name: uv-cache
|
||||
path: *uv_cache_dir
|
||||
|
||||
volumes:
|
||||
- name: uv-cache
|
||||
temp: {}
|
||||
Reference in New Issue
Block a user