Github action for CI added

This commit is contained in:
Nicolas 2025-05-13 10:03:09 +02:00
parent 807cb96638
commit bda9d046ee
2 changed files with 48 additions and 1 deletions

47
.github/workflows/ci.yml vendored Normal file
View File

@ -0,0 +1,47 @@
name: CI Pipeline
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", 3.11, 3.12, 3.13]
steps:
- name: Check out code
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install LaTeX
run: sudo apt-get install -y texlive-latex-extra texlive-fonts-extra lmodern texlive-xetex texlive-science
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip
python -m pip install -e .[dev]
- name: Lint code with flake8
run: flake8
- name: Type checking with mypy
run: mypy
- name: Run tests with pytest
run: pytest
- name: Upload rendered files
uses: actions/upload-artifact@v4
with:
name: rendering-results
path: tests/out/test_*_render*

View File

@ -7,9 +7,9 @@ authors = [
description = "Package for generating HTML and PDF/latex from python code" description = "Package for generating HTML and PDF/latex from python code"
readme = "README.md" readme = "README.md"
requires-python = ">=3.8" requires-python = ">=3.8"
license = "MIT"
classifiers = [ classifiers = [
"Programming Language :: Python :: 3", "Programming Language :: Python :: 3",
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent", "Operating System :: OS Independent",
] ]
dependencies = [ dependencies = [