Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 6 additions & 8 deletions .github/workflows/prebuilds.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,19 @@ name: Prebuilds
# Release for the pushed tag. Runs on `v*` tag push. Two parallel tracks:
#
# 1. Node N-API binaries (via `prebuildify`) for linux x64/arm64,
# macos x64/arm64, windows x64. Consumed by `node-gyp-build` at
# macos arm64, windows x64. Consumed by `node-gyp-build` at
# npm-install time so end users don't need a C toolchain.
#
# 2. Python wheels (via `cibuildwheel`) for the same five (os, arch)
# 2. Python wheels (via `cibuildwheel`) for the same four (os, arch)
# pairs. Built once per platform with `cp310-abi3` (forward-compat
# with cp310+) so a single wheel covers Python 3.10 through 3.13+.
# Downstream Python consumers (notably `m-cli`) URL-pin to the
# release artifact instead of cloning a sibling checkout.
#
# macOS x86_64 (Intel) is intentionally NOT in the matrix — Apple Silicon
# is the modern macOS target, and GitHub's free `macos-13` Intel queue
# is unreliable enough to block release uploads when it stalls.
#
# To consume Node prebuilds locally before `npm publish` (RELEASE.md §3):
# gh release download "v$NEW" -p 'prebuilds-*.tar.gz' -D /tmp/ts-m-prebuilds
# for f in /tmp/ts-m-prebuilds/prebuilds-*.tar.gz; do tar -xzf "$f"; done
Expand Down Expand Up @@ -52,9 +56,6 @@ jobs:
- os: linux
arch: arm64
runner: ubuntu-22.04-arm
- os: macos
arch: x64
runner: macos-13
- os: macos
arch: arm64
runner: macos-14
Expand Down Expand Up @@ -105,9 +106,6 @@ jobs:
- os: linux
arch: aarch64
runner: ubuntu-22.04-arm
- os: macos
arch: x86_64
runner: macos-13
- os: macos
arch: arm64
runner: macos-14
Expand Down
24 changes: 12 additions & 12 deletions RELEASE.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,15 @@ checklist; do not skip steps.

> **Python binding.** The Python binding is **not** published to
> PyPI. Instead, `cibuildwheel` builds prebuilt wheels for linux
> x64/arm64, macos x64/arm64, and windows x64 on every `v*` tag
> push (`.github/workflows/prebuilds.yml`), and attaches them to
> the GitHub Release. Python consumers (notably `m-cli`) URL-pin
> to those release assets — no PyPI account, no `twine`, no
> sibling clone required. See §5.5 below for the wheel-pinning
> pattern downstream consumers use.
> x64/arm64, macos arm64, and windows x64 on every `v*` tag push
> (`.github/workflows/prebuilds.yml`), and attaches them to the
> GitHub Release. Python consumers (notably `m-cli`) URL-pin to
> those release assets — no PyPI account, no `twine`, no sibling
> clone required. See §5.5 below for the wheel-pinning pattern
> downstream consumers use. **macOS Intel (x86_64) is not in the
> matrix** — Apple Silicon is the modern target and GitHub's
> `macos-13` Intel queue is unreliable enough to stall release
> uploads.

> **First-publish note.** The initial public release is **0.1.0**
> — all four binding scaffolds work locally and across the CI
Expand Down Expand Up @@ -121,7 +124,7 @@ node -e "const P=require('tree-sitter'); const M=require('tree-sitter-m');

**Prebuilds** (now wired): `.github/workflows/prebuilds.yml` runs
on `v*` tag push and produces two parallel artifact tracks for the
same five (os, arch) pairs (linux-x64/arm64, macos-x64/arm64,
same four (os, arch) pairs (linux-x64/arm64, macos-arm64,
windows-x64):

- **Node N-API binaries** — one `prebuilds-<os>-<arch>.tar.gz` per
Expand Down Expand Up @@ -221,14 +224,13 @@ go run main.go
## 5.5. Python wheels — verify, then update consumer pins

The `prebuilds.yml` workflow (triggered by step 5's tag push) builds
five wheels via `cibuildwheel`. After the workflow's
four wheels via `cibuildwheel`. After the workflow's
`attach-to-release` job finishes, the GitHub Release for `v$NEW`
will carry:

```
tree_sitter_m-$NEW-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
tree_sitter_m-$NEW-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
tree_sitter_m-$NEW-cp310-abi3-macosx_10_9_x86_64.whl
tree_sitter_m-$NEW-cp310-abi3-macosx_11_0_arm64.whl
tree_sitter_m-$NEW-cp310-abi3-win_amd64.whl
```
Expand Down Expand Up @@ -258,8 +260,6 @@ tree-sitter-m = [
marker = "sys_platform == 'linux' and platform_machine == 'x86_64'" },
{ url = "https://github.com/m-dev-tools/tree-sitter-m/releases/download/v$NEW/tree_sitter_m-$NEW-cp310-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl",
marker = "sys_platform == 'linux' and platform_machine == 'aarch64'" },
{ url = "https://github.com/m-dev-tools/tree-sitter-m/releases/download/v$NEW/tree_sitter_m-$NEW-cp310-abi3-macosx_10_9_x86_64.whl",
marker = "sys_platform == 'darwin' and platform_machine == 'x86_64'" },
{ url = "https://github.com/m-dev-tools/tree-sitter-m/releases/download/v$NEW/tree_sitter_m-$NEW-cp310-abi3-macosx_11_0_arm64.whl",
marker = "sys_platform == 'darwin' and platform_machine == 'arm64'" },
{ url = "https://github.com/m-dev-tools/tree-sitter-m/releases/download/v$NEW/tree_sitter_m-$NEW-cp310-abi3-win_amd64.whl",
Expand Down Expand Up @@ -291,7 +291,7 @@ gh release create "v$NEW" \
- crates.io: https://crates.io/crates/tree-sitter-m/$NEW
- Go: `go get github.com/m-dev-tools/tree-sitter-m@v$NEW`
- Python wheels: attached to this release (linux x64/arm64,
macos x64/arm64, windows x64). cp310-abi3 — one wheel covers
macos arm64, windows x64). cp310-abi3 — one wheel covers
Python 3.10 through the latest stable.

## Status
Expand Down
Loading