Skip to content

add templates to support float64 (#4) #10

add templates to support float64 (#4)

add templates to support float64 (#4) #10

name: Build python package
on:
push:
branches: [main]
tags: ['v*']
pull_request:
branches: [main]
workflow_dispatch:
jobs:
build_wheels:
name: Build wheels for ${{ matrix.platform-id }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- os: ubuntu-20.04
platform-id: manylinux_x86_64
- os: windows-2019
platform-id: win_amd64
- os: macos-latest
platform-id: macosx_x86_64
- os: macos-latest
platform-id: macosx_arm64
steps:
- uses: actions/checkout@v4
- name: Build wheels
uses: pypa/[email protected]
env:
CIBW_BUILD: cp38-${{ matrix.platform-id }}
CIBW_ARCHS: all
CIBW_TEST_SKIP: '*-macosx_arm64'
- uses: actions/upload-artifact@v3
if: github.event_name == 'push'
with:
path: ./wheelhouse/*.whl
build_sdist:
name: Build sdist
if: github.event_name == 'push'
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v4
with:
python-version: '3.8'
- name: Build sdist
run: |
python -m pip install build scikit-build-core
python -m build --sdist --outdir dist
- uses: actions/upload-artifact@v3
with:
path: ./dist/*.tar.gz
upload_artifacts:
name: 'Upload to PyPI'
if: github.repository == 'Nixtla/coreforecast' && startsWith(github.ref, 'refs/tags/v')
needs: [build_wheels, build_sdist]
runs-on: ubuntu-latest
permissions:
id-token: write
steps:
- uses: actions/download-artifact@v3
with:
name: artifact
path: dist
- name: Publish package to PyPI
uses: pypa/gh-action-pypi-publish@release/v1