Skip to content

Trying cibuildwheel with win and linux GH actions #223

Trying cibuildwheel with win and linux GH actions

Trying cibuildwheel with win and linux GH actions #223

Workflow file for this run

name: Ubuntu
on:
push:
branches: [ "master", "dev_actions" ]
tags: [ '**' ]
jobs:
build-ubuntu:
runs-on: ${{ matrix.os }}
timeout-minutes: 30
strategy:
fail-fast: true
matrix:
os : [ubuntu-latest]
python-version: ["3.11"]
#python-version: ["3.12", "3.11", "3.10", "3.9"]
steps:
# if matrix.force is not true or event is not tag, skip
- if: ${{ matrix.force }} != true || (github.event_name == 'push' && !startsWith(github.ref, 'refs/tags'))
run:
echo "Skipping job for ${{ matrix.os }} ${{ matrix.python-version }}"
exit 0
- name: Check out repository
uses: actions/checkout@v3
- name: Setup python
uses: actions/setup-python@v3
with:
python-version: ${{ matrix.python-version }}
architecture: x64
- name: Display Python version
run: |
python -c "import sys; print(sys.version)"
- name: Install setuptools (needed from Python 3.12)
run: pip install setuptools
- name: Set up GraalVM Native Image toolchain
uses: graalvm/setup-graalvm@v1
with:
java-version: '22'
distribution: 'graalvm'
- name: Install Swig
run: sudo apt-get install swig
- name: Update repository
run: |
git submodule update --init --recursive
- name: Build
run: |
sh build.sh nowheel
pip install pychoco -f dist/
- name: Build wheels
uses: pypa/[email protected]
with:
output-dir: dist
- name: Test
run: |
pip install pytest
pip install -r requirements_tests.txt
pytest
- name: Generate Report
run: |
pip install coverage
coverage run -m unittest
- name: Upload Coverage to Codecov
uses: codecov/codecov-action@v3
- name: Upload to PyPi
#if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
uses: pypa/gh-action-pypi-publish@release/v1
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
verbose: true