Skip to content

Commit 655b2b4

Browse files
✨ Add cross-platform support
2 parents 02c1686 + 56f0830 commit 655b2b4

File tree

10 files changed

+336
-227
lines changed

10 files changed

+336
-227
lines changed

.github/workflows/integration.yml

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
name: Integration Tests
2+
3+
on:
4+
workflow_dispatch:
5+
push:
6+
branches: [ main ]
7+
paths:
8+
- 'every_python/**'
9+
- '.github/workflows/integration.yml'
10+
pull_request:
11+
branches: [ main ]
12+
paths:
13+
- 'every_python/**'
14+
- '.github/workflows/integration.yml'
15+
16+
jobs:
17+
integration:
18+
runs-on: ${{ matrix.runner }}
19+
strategy:
20+
fail-fast: false
21+
matrix:
22+
include:
23+
- runner: ubuntu-24.04
24+
os: Linux
25+
- runner: windows-2022
26+
os: Windows
27+
- runner: macos-14
28+
os: macOS
29+
steps:
30+
- uses: actions/checkout@v5
31+
32+
- name: Set up Python
33+
uses: actions/setup-python@v5
34+
with:
35+
python-version: "3.14"
36+
37+
- name: Install system dependencies (Linux)
38+
if: runner.os == 'Linux'
39+
run: |
40+
sudo apt-get update
41+
sudo apt-get install -y lsof
42+
sudo bash -c "$(wget -O - https://apt.llvm.org/llvm.sh)" ./llvm.sh 20
43+
echo "$(llvm-config-20 --bindir)" >> $GITHUB_PATH
44+
45+
- name: Install LLVM (macOS)
46+
if: runner.os == 'macOS'
47+
run: brew install llvm@20
48+
49+
- name: Install uv
50+
uses: astral-sh/setup-uv@v7
51+
with:
52+
enable-cache: true
53+
54+
- name: Install dependencies
55+
run: uv sync --all-groups
56+
57+
- name: Install package in editable mode
58+
run: uv pip install -e .
59+
60+
- name: Test LLVM detection (Linux/macOS)
61+
if: runner.os != 'Windows'
62+
run: |
63+
uv run python -c "from every_python.utils import check_llvm_available; import sys; sys.exit(0 if check_llvm_available('20') else 1)"
64+
65+
- name: Test build without JIT
66+
run: uv run every-python install v3.13.0 --verbose
67+
68+
- name: Verify non-JIT build works
69+
run: uv run every-python run v3.13.0 -- --version
70+
71+
- name: Test build with JIT
72+
run: uv run every-python install main --jit --verbose
73+
74+
- name: Verify JIT build works
75+
run: uv run every-python run main --jit -- --version

.github/workflows/lint.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,14 @@ on:
44
push:
55
branches: [ main ]
66
paths:
7-
- 'every-python/**/*.py'
7+
- 'every_python/**'
8+
- 'tests/**'
89
- '.github/workflows/lint.yml'
910
pull_request:
1011
branches: [ main ]
1112
paths:
12-
- 'every-python/**/*.py'
13+
- 'every_python/**'
14+
- 'tests/**'
1315
- '.github/workflows/lint.yml'
1416

1517
jobs:
@@ -32,7 +34,7 @@ jobs:
3234
run: uv sync
3335

3436
- name: Run Ruff linter
35-
run: uv run ruff check every-python/
37+
run: uv run ruff check every_python/
3638

3739
- name: Run Ruff formatter
38-
run: uv run ruff format --check every-python/
40+
run: uv run ruff format --check every_python/

.github/workflows/test.yml

Lines changed: 29 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,31 +4,50 @@ on:
44
push:
55
branches: [ main ]
66
paths:
7-
- 'every-python/**'
7+
- 'every_python/**'
8+
- 'tests/**'
9+
- 'pyproject.toml'
810
- '.github/workflows/test.yml'
911
pull_request:
1012
branches: [ main ]
1113
paths:
12-
- 'every-python/**'
14+
- 'every_python/**'
15+
- 'tests/**'
16+
- 'pyproject.toml'
1317
- '.github/workflows/test.yml'
1418

1519
jobs:
1620
test:
17-
runs-on: ${{ matrix.os }}
21+
runs-on: ${{ matrix.runner }}
1822
strategy:
23+
fail-fast: false
1924
matrix:
20-
os: [ubuntu-latest, windows-latest, macos-latest]
25+
include:
26+
- target: x86_64-unknown-linux-gnu/gcc
27+
architecture: x86_64
28+
runner: ubuntu-24.04
29+
- target: aarch64-unknown-linux-gnu/gcc
30+
architecture: aarch64
31+
runner: ubuntu-24.04-arm
32+
- target: x86_64-pc-windows-msvc/msvc
33+
architecture: x64
34+
runner: windows-2022
35+
- target: aarch64-pc-windows-msvc/msvc
36+
architecture: ARM64
37+
runner: windows-11-arm
38+
- target: x86_64-apple-darwin/clang
39+
architecture: x86_64
40+
runner: macos-15-intel
41+
- target: aarch64-apple-darwin/clang
42+
architecture: aarch64
43+
runner: macos-14
2144
steps:
2245
- uses: actions/checkout@v5
2346

2447
- name: Set up Python
25-
uses: actions/setup-python@v6
48+
uses: actions/setup-python@v5
2649
with:
27-
python-version: "3.13"
28-
29-
- name: Install system dependencies (Linux only)
30-
if: runner.os == 'Linux'
31-
run: sudo apt-get update && sudo apt-get install -y lsof
50+
python-version: "3.14"
3251

3352
- name: Install uv
3453
uses: astral-sh/setup-uv@v7

.github/workflows/typecheck.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,16 @@ on:
44
push:
55
branches: [ main ]
66
paths:
7-
- 'every-python/**/*.py'
8-
- 'every-python/pyproject.toml'
7+
- 'every_python/**'
8+
- 'tests/**'
9+
- 'pyproject.toml'
910
- '.github/workflows/typecheck.yml'
1011
pull_request:
1112
branches: [ main ]
1213
paths:
13-
- 'every-python/**/*.py'
14-
- 'every-python/pyproject.toml'
14+
- 'every_python/**'
15+
- 'tests/**'
16+
- 'pyproject.toml'
1517
- '.github/workflows/typecheck.yml'
1618

1719
jobs:

0 commit comments

Comments
 (0)