mirror of
https://github.com/cdtools-developers/cdtools.git
synced 2026-09-10 05:22:41 +02:00
refactor: CI installation process to use 'uv' for faster dependency management
This commit is contained in:
+11
-10
@@ -22,14 +22,15 @@ jobs:
|
||||
with:
|
||||
python-version: ${{ matrix.python-version }}
|
||||
|
||||
- name: Install dependencies
|
||||
- name: Install uv
|
||||
run: |
|
||||
pip install --upgrade pip
|
||||
pip install -r requirements.txt
|
||||
pip install -e . --no-deps
|
||||
pip install uv
|
||||
- name: Install dependencies with uv
|
||||
run: |
|
||||
uv pip install ."[tests]"
|
||||
|
||||
- name: Run tests
|
||||
run: pytest
|
||||
run: python -m pytest
|
||||
|
||||
build-docs:
|
||||
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
|
||||
@@ -52,12 +53,12 @@ jobs:
|
||||
with:
|
||||
python-version: '3.9'
|
||||
|
||||
- name: Install dependencies
|
||||
- name: Install uv
|
||||
run: |
|
||||
pip install --upgrade pip
|
||||
pip install -r requirements.txt
|
||||
pip install sphinx sphinx_rtd_theme sphinx-argparse
|
||||
pip install -e . --no-deps
|
||||
pip install uv
|
||||
- name: Install dependencies with uv
|
||||
run: |
|
||||
uv pip install ."[docs]""
|
||||
|
||||
- name: Build docs
|
||||
working-directory: docs
|
||||
|
||||
@@ -19,12 +19,14 @@ jobs:
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: "3.x"
|
||||
- name: Install dependencies
|
||||
- name: Install uv
|
||||
run: |
|
||||
python -m pip install --upgrade pip
|
||||
pip install setuptools wheel
|
||||
- name: Build package (setup.py)
|
||||
pip install uv
|
||||
- name: Install project with uv
|
||||
run: |
|
||||
python setup.py sdist bdist_wheel
|
||||
uv pip install -e .
|
||||
- name: Build package with uv
|
||||
run: |
|
||||
uv build
|
||||
- name: Publish package distributions to PyPI
|
||||
uses: pypa/gh-action-pypi-publish@release/v1
|
||||
Reference in New Issue
Block a user