mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-04-25 21:06:23 +02:00
github-actions: update jobs
This commit is contained in:
parent
06b425edb2
commit
05b4a70785
2 changed files with 42 additions and 53 deletions
|
|
@ -1,8 +1,10 @@
|
|||
name: "Deploy Python Lib"
|
||||
name: "Test Python Lib"
|
||||
on:
|
||||
release:
|
||||
types:
|
||||
- created
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
- devel
|
||||
- deploy
|
||||
pull_request:
|
||||
|
||||
permissions:
|
||||
|
|
@ -10,6 +12,35 @@ permissions:
|
|||
pull-requests: read
|
||||
|
||||
jobs:
|
||||
test:
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||
python: ['3.9', '3.10', '3.11', '3.12']
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: ${{ matrix.python }}
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
pip install setuptools
|
||||
pip install matplotlib
|
||||
pip install pytest
|
||||
|
||||
- name: Install lib
|
||||
run: |
|
||||
python setup.py develop
|
||||
|
||||
- name: pytest
|
||||
run: |
|
||||
pytest GPy/testing
|
||||
|
||||
build-windows:
|
||||
strategy:
|
||||
matrix:
|
||||
|
|
@ -124,7 +155,7 @@ jobs:
|
|||
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
needs: [build-linux, build-windows, build-mac]
|
||||
needs: [test, build-linux, build-windows, build-mac]
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
|
@ -138,7 +169,7 @@ jobs:
|
|||
run: |
|
||||
pip install --upgrade pip
|
||||
pip install twine
|
||||
|
||||
|
||||
- name: Download all artifacts to a specific directory
|
||||
uses: actions/download-artifact@v3
|
||||
with:
|
||||
|
|
@ -148,8 +179,8 @@ jobs:
|
|||
run: |
|
||||
ls -R dist
|
||||
|
||||
# - name: Upload to PyPI using twine
|
||||
# run: twine upload --skip-existing wheelhouse/*
|
||||
# env:
|
||||
# TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
|
||||
# TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
|
||||
- name: Upload to PyPI using twine
|
||||
run: twine upload --skip-existing wheelhouse/*
|
||||
env:
|
||||
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
|
||||
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
|
||||
42
.github/workflows/test.yml
vendored
42
.github/workflows/test.yml
vendored
|
|
@ -1,42 +0,0 @@
|
|||
name: "Test Python Lib"
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
- devel
|
||||
- deploy
|
||||
pull_request:
|
||||
|
||||
permissions:
|
||||
contents: read
|
||||
pull-requests: read
|
||||
|
||||
jobs:
|
||||
develop-matrix:
|
||||
strategy:
|
||||
matrix:
|
||||
os: [ubuntu-latest, windows-latest, macos-latest]
|
||||
python: ['3.9', '3.10', '3.11', '3.12']
|
||||
runs-on: ${{ matrix.os }}
|
||||
steps:
|
||||
- name: Checkout
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Setup python
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: ${{ matrix.python }}
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
pip install setuptools
|
||||
pip install matplotlib
|
||||
pip install pytest
|
||||
|
||||
- name: Install lib
|
||||
run: |
|
||||
python setup.py develop
|
||||
|
||||
- name: pytest
|
||||
run: |
|
||||
pytest GPy/testing
|
||||
Loading…
Add table
Add a link
Reference in a new issue