Skip to content

Commit

Permalink
add ci
Browse files Browse the repository at this point in the history
  • Loading branch information
kaihsin committed Dec 23, 2024
1 parent 42e70af commit e71c2cc
Show file tree
Hide file tree
Showing 3 changed files with 616 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Publish
on:
pull_request:
push:
branches:
- main
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true


jobs:
uv-test:
name: python
runs-on: ubuntu-latest

strategy:
matrix:
python-version:
- "3.10"
- "3.11"
- "3.12"

steps:
- uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v3
with:
# Install a specific version of uv.
version: "0.5.1"
enable-cache: true
cache-dependency-glob: "uv.lock"

- name: Setup Python ${{ matrix.python-version }}
run: uv python install ${{ matrix.python-version }}

- name: Install the project
run: uv sync --all-extras --dev

- name: Build
run: uv build

- name: Audit manylinux
run: |
uv run auditwheel --manylinux 2_17 dist/*whl --exclude libscipy_openblas64_.so
uv run twine upload wheelhouse/*manylinux* -p ${{ secrets.PYPI_TOKEN }}
4 changes: 4 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ authors = [
]
requires-python = ">=3.10"
dependencies = [
"cibuildwheel>=2.22.0",
"numpy>=2.2.0",
"scipy-openblas64>=0.3.28.0.2",
]
Expand Down Expand Up @@ -77,4 +78,7 @@ dev = [
"pre-commit>=4.0.1",
"pytest>=8.3.3",
"ruff>=0.7.4",
"auditwheel-symbols>=0.1.13",
"auditwheel>=6.1.0",
"twine>=6.0.1",
]
Loading

0 comments on commit e71c2cc

Please sign in to comment.