Skip to content

Commit

Permalink
update ci (#38)
Browse files Browse the repository at this point in the history
* update ci

* simplify config

* comment out pre-commit for now
  • Loading branch information
kylebarron authored Aug 22, 2024
1 parent 6af82ca commit 2a57288
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 30 deletions.
30 changes: 15 additions & 15 deletions .github/workflows/build-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ name: Build Wheels
on:
push:
tags:
- 'v*'
- "v*"

jobs:
build_wheels:
Expand All @@ -15,21 +15,21 @@ jobs:
os: [ubuntu-latest, macos-11]

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v2

- name: Build wheels
uses: pypa/cibuildwheel@v2.11.2
env:
# From rio-color here:
# https://github.com/mapbox/rio-color/blob/0ab59ad8e2db99ad1d0c8bd8c2e4cf8d0c3114cf/appveyor.yml#L3
CIBW_SKIP: "cp2* cp35* pp* *-win32 *-manylinux_i686"
CIBW_ARCHS_MACOS: x86_64 arm64
CIBW_BEFORE_BUILD_MACOS: brew install glm
CIBW_BEFORE_ALL_LINUX: curl -sL https://github.com/g-truc/glm/releases/download/0.9.9.8/glm-0.9.9.8.zip > glm.zip && unzip -q glm.zip && cp -r glm/glm/ /usr/include/
- name: Build wheels
uses: pypa/cibuildwheel@v2.11.2
env:
# From rio-color here:
# https://github.com/mapbox/rio-color/blob/0ab59ad8e2db99ad1d0c8bd8c2e4cf8d0c3114cf/appveyor.yml#L3
CIBW_SKIP: "cp2* cp35* pp* *-win32 *-manylinux_i686"
CIBW_ARCHS_MACOS: x86_64 arm64
CIBW_BEFORE_BUILD_MACOS: brew install glm
CIBW_BEFORE_ALL_LINUX: curl -sL https://github.com/g-truc/glm/releases/download/0.9.9.8/glm-0.9.9.8.zip > glm.zip && unzip -q glm.zip && cp -r glm/glm/ /usr/include/

- uses: actions/upload-artifact@v2
with:
path: ./wheelhouse/*.whl
- uses: actions/upload-artifact@v2
with:
path: ./wheelhouse/*.whl

build_sdist:
name: Build source distribution
Expand All @@ -40,7 +40,7 @@ jobs:
- uses: actions/setup-python@v2
name: Install Python
with:
python-version: '3.7'
python-version: "3.11"

- name: Build sdist
run: |
Expand Down
19 changes: 10 additions & 9 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ name: CI
on:
push:
branches:
- master
- master
tags:
- '*'
- "*"
pull_request:

jobs:
tests:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: [3.6, 3.7, 3.8, 3.9]
python-version: [3.9]

steps:
- uses: actions/checkout@v2
Expand All @@ -34,9 +34,10 @@ jobs:
# - name: Run tests
# run: pytest

# Run pre-commit (only for python-3.8)
- name: run pre-commit
if: matrix.python-version == 3.8
run: |
python -m pip install pre-commit
pre-commit run --all-files
# TODO: re-enable pre-commit
# # Run pre-commit (only for python-3.9)
# - name: run pre-commit
# if: matrix.python-version == 3.9
# run: |
# python -m pip install pre-commit
# pre-commit run --all-files
7 changes: 1 addition & 6 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,12 @@ repos:
rev: 5.4.2
hooks:
- id: isort
language_version: python3.8

- repo: https://github.com/psf/black
rev: 22.10.0
hooks:
- id: black
args:
[
"--skip-string-normalization",
]
args: ["--skip-string-normalization"]
language_version: python3

- repo: https://github.com/PyCQA/pylint
Expand All @@ -41,5 +37,4 @@ repos:
rev: v0.812
hooks:
- id: mypy
language_version: python3.8
args: ["--ignore-missing-imports"]

0 comments on commit 2a57288

Please sign in to comment.