Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
382 commits
Select commit Hold shift + click to select a range
1d6c02a
Align implicit format package discovery
cknitt Sep 9, 2026
910fc03
Format source files concurrently
cknitt Sep 9, 2026
b5a5ea2
Report after-build command failures
cknitt Sep 9, 2026
9436fac
Retain JS post-build failure context
cknitt Sep 9, 2026
d4e1e9a
Filter exotic namespace map entries
cknitt Sep 9, 2026
ca25350
Record dormant dependency permission behavior
cknitt Sep 9, 2026
1878a3c
Record consistent watch filter behavior
cknitt Sep 9, 2026
a7802aa
Match source filters against basenames
cknitt Sep 9, 2026
8b899c2
Document source filter regex gap
cknitt Sep 9, 2026
be750ad
Match redirected clean progress
cknitt Sep 9, 2026
3d1b75e
Align failure output and cycle selection
cknitt Sep 9, 2026
a8eeca1
Cover explicit format failures
cknitt Sep 9, 2026
00e841d
Cover implicit format project errors
cknitt Sep 9, 2026
1d8e40c
Contextualize formatter file errors
cknitt Sep 9, 2026
f69af1d
Document dependency permission diagnostics
cknitt Sep 9, 2026
930137a
Validate runtime discovery failures
cknitt Sep 9, 2026
dd0aaa8
Retain package discovery diagnostics
cknitt Sep 9, 2026
dce7f8e
Cover configuration diagnostic context
cknitt Sep 9, 2026
1e27723
Close ordinary redirected output inventory
cknitt Sep 9, 2026
a5cdeff
Cover disappearing parser sources
cknitt Sep 9, 2026
f348767
Extract project context policy
cknitt Sep 9, 2026
7167426
Extract compiler log lifecycle
cknitt Sep 9, 2026
e0f1779
Extract compiler argument policy
cknitt Sep 9, 2026
3a5e7c7
Record post-refactor canonical validation
cknitt Sep 9, 2026
cd56c6b
Extract build lock lifecycle
cknitt Sep 9, 2026
db66f42
Centralize OCaml rewatch version
cknitt Sep 9, 2026
c383e07
Extract compiler scheduling state machine
cknitt Sep 9, 2026
61d02c6
Extract watch lifecycle
cknitt Sep 9, 2026
2a4bc26
Extract compiler args command
cknitt Sep 9, 2026
115a287
Extract compiler process lifecycle
cknitt Sep 9, 2026
b3ba166
Extract clean and package diagnostics
cknitt Sep 9, 2026
ab038f4
Extract OCaml build cycle state
cknitt Sep 9, 2026
16ed59d
Extract OCaml package graph discovery
cknitt Sep 9, 2026
97aa9ec
Extract OCaml build freshness checks
cknitt Sep 10, 2026
9cd0912
Extract after-build command execution
cknitt Sep 10, 2026
29897da
Extract OCaml build preparation
cknitt Sep 10, 2026
a5af26b
Extract OCaml package build planning
cknitt Sep 10, 2026
095fa51
Split OCaml configuration decoding
cknitt Sep 10, 2026
f811348
Use OCaml character range patterns
cknitt Sep 10, 2026
9e55d65
Make OCaml directory creation race-safe
cknitt Sep 10, 2026
5744f80
Match quiet build and watch output
cknitt Sep 10, 2026
01ad9f4
Extract general OCaml filesystem utilities
cknitt Sep 10, 2026
0f2eb35
Make OCaml lock ownership interruption-safe
cknitt Sep 10, 2026
d9bbb54
Protect OCaml capture pipe acquisition
cknitt Sep 10, 2026
d6c8f8d
Wake OCaml scheduler on child completion
cknitt Sep 10, 2026
3884902
Clarify OCaml module ownership
cknitt Sep 10, 2026
b7d1ce9
Tighten OCaml build module boundary
cknitt Sep 10, 2026
2ed08c3
Reuse OCaml filesystem cleanup helper
cknitt Sep 10, 2026
6871645
Harden OCaml watch recovery and file publication
cknitt Sep 10, 2026
7e6eecb
Record OCaml rewatch performance gate
cknitt Sep 10, 2026
4c3b079
Accept Cmdliner unknown-option rendering in CLI tests
cknitt Sep 10, 2026
7ff4be2
Make rewatch unit fixtures path-canonical
cknitt Sep 10, 2026
84c84d9
Handle case-insensitive rewatch test filesystems
cknitt Sep 10, 2026
28a9644
Align dependency resolution and lock ownership
cknitt Sep 10, 2026
e85f7a7
Support the OCaml 5.0 thread API
cknitt Sep 10, 2026
847493b
Support OCaml 5.0 in rewatch tests
cknitt Sep 10, 2026
272f654
Patch Luv for ARM64 musl static builds
cknitt Sep 10, 2026
5ea86fa
Fix namespaced dependency graph resolution
cknitt Sep 10, 2026
b16bdce
Close rewatch CLI output parity gaps
cknitt Sep 10, 2026
a42741e
Update rewatch config diagnostic snapshot
cknitt Sep 10, 2026
f94aaa5
Update remaining rewatch diagnostic snapshots
cknitt Sep 10, 2026
454ab22
Scope direct workspace package dependencies
cknitt Sep 10, 2026
0cfb407
Fix interactive configuration warning output
cknitt Sep 10, 2026
e6c4503
Retain build state across source watch edits
cknitt Sep 10, 2026
2accc6c
Stabilize CommonJS test dependency setup
cknitt Sep 10, 2026
8a17977
Update retained watch dependency graph
cknitt Sep 10, 2026
688ef1e
Match rewatch terminal color policy
cknitt Sep 10, 2026
823ad33
Use native event paths for watch edits
cknitt Sep 10, 2026
f6371ab
Match verbose builds and watcher recovery
cknitt Sep 10, 2026
08b8791
Match interactive build progress
cknitt Sep 10, 2026
54c8181
Harden retained watcher lifecycle
cknitt Sep 11, 2026
0fb8812
Exercise watcher polling fallback
cknitt Sep 11, 2026
f68ccde
Reject conflicting CLI verbosity
cknitt Sep 11, 2026
f861d2c
Statically link OCaml rewatch releases
cknitt Sep 11, 2026
e6ef5ee
Complete rewatch release inventories
cknitt Sep 11, 2026
4de649f
Use maintained source filter regexes
cknitt Sep 11, 2026
9a86551
Own Windows subprocess trees atomically
cknitt Sep 11, 2026
2c0dd8d
Harden rewatch command lifecycle
cknitt Sep 11, 2026
7aeab3c
Document rewatch release inventories
cknitt Sep 11, 2026
e718f25
Narrow rewatch internal interfaces
cknitt Sep 11, 2026
072df5e
Complete rewatch module interfaces
cknitt Sep 11, 2026
7367d9c
Close rewatch interface and performance gates
cknitt Sep 11, 2026
eec10f2
Align rewatch cleanup and publication phases
cknitt Sep 11, 2026
03fc098
Align rewatch command phase ordering
cknitt Sep 11, 2026
e8e5bf1
Canonicalize rewatch command test workspace
cknitt Sep 11, 2026
436e46a
Align rewatch parser result reporting
cknitt Sep 11, 2026
14e87df
Align rewatch compiler-args phases
cknitt Sep 11, 2026
aca9d1a
Document rewatch clean safety improvements
cknitt Sep 11, 2026
b1b893b
Align rewatch watch phase boundaries
cknitt Sep 11, 2026
02665b1
Record rewatch phase audit completion
cknitt Sep 11, 2026
b396286
Preserve rewatch CMI invalidation after failure
cknitt Sep 11, 2026
6f90be0
Correct rewatch source watch scope
cknitt Sep 11, 2026
3f76265
Merge overlapping rewatch source coverage
cknitt Sep 11, 2026
6d57cd7
Block all rewatch dependency cycles
cknitt Sep 11, 2026
b101839
Index rewatch dependency graph construction
cknitt Sep 11, 2026
256926e
Remove obsolete rewatch output sidecars
cknitt Sep 11, 2026
2d668fb
Simplify rewatch cleanup discovery
cknitt Sep 11, 2026
aa7d5de
Close rewatch review cleanup phase
cknitt Sep 11, 2026
ec08b10
Align rewatch compilation worker lifecycle
cknitt Sep 11, 2026
39060e4
Require prepared rewatch package state
cknitt Sep 11, 2026
aade461
Consolidate rewatch dependency state
cknitt Sep 11, 2026
22c0cae
Centralize rewatch build cleanup
cknitt Sep 11, 2026
44a3246
Share rewatch compiler argument construction
cknitt Sep 11, 2026
171b51e
Use normal variants for closed rewatch state
cknitt Sep 11, 2026
00db7cf
Record post-alignment rewatch benchmark
cknitt Sep 11, 2026
146d9a4
Preserve CMI invalidation across publication failures
cknitt Sep 11, 2026
c2db92c
Overlap parser job preparation with execution
cknitt Sep 11, 2026
7910160
Record demand-driven parser benchmark
cknitt Sep 11, 2026
18b848f
Report peak task count in rewatch benchmarks
cknitt Sep 11, 2026
aed4f92
Record stable post-review rewatch benchmark
cknitt Sep 11, 2026
b885a3a
Document measured rewatch capture overhead
cknitt Sep 11, 2026
65cb04e
Make watch lock validation package-name independent
cknitt Sep 11, 2026
ee457f0
Document the native Windows rewatch handoff
cknitt Sep 11, 2026
401e1d1
Separate open rewatch gaps from completed evidence
cknitt Sep 11, 2026
ed355cf
Fix retained rewatch correctness and shared package state
cknitt Sep 11, 2026
b75b7e2
Close the non-Windows rewatch release inventory
cknitt Sep 11, 2026
4626de3
Match interactive clean phase output
cknitt Sep 11, 2026
feaf619
Fix retained rewatch graph and watcher state
cknitt Sep 11, 2026
d254671
Enable formatting for OCaml rewatch
cknitt Sep 11, 2026
705c701
Reduce retained rewatch preparation work
cknitt Sep 11, 2026
ee4ff61
Document latest rewatch review work
cknitt Sep 11, 2026
67ccc38
Watch transitive local dependencies
cknitt Sep 11, 2026
b018fcf
Update rewatch review checkpoint
cknitt Sep 11, 2026
d21f43b
Record latest rewatch verification
cknitt Sep 11, 2026
eb99642
Record full rewatch repository gate
cknitt Sep 11, 2026
b0d73a0
Refresh rewatch packaging checkpoint
cknitt Sep 11, 2026
a8cf156
Record stable rewatch performance comparison
cknitt Sep 11, 2026
5c56366
Investigate rewatch performance ratio variance
cknitt Sep 11, 2026
b5cd306
Record stable historical rewatch comparison
cknitt Sep 11, 2026
e89a12f
Stabilize interactive clean output check
cknitt Sep 11, 2026
23c2263
Preserve pending work across dependency cycles
cknitt Sep 11, 2026
4cbb80b
Fix rewatch resolution and stale output tracking
cknitt Sep 11, 2026
9362efa
Share rewatch traversal and lifecycle policies
cknitt Sep 11, 2026
8988e4f
Stabilize cross-platform rewatch output checks
cknitt Sep 11, 2026
ed42977
Cover rewatch namespace restart and feature watches
cknitt Sep 11, 2026
f0d7e2c
Document latest rewatch review resolution
cknitt Sep 11, 2026
6d17bf7
Refresh native Windows rewatch handoff
cknitt Sep 11, 2026
5338c5e
Record rewatch subprocess thread profile
cknitt Sep 11, 2026
44c79ed
Narrow remaining rewatch performance hypothesis
cknitt Sep 11, 2026
6ca9d11
Run rewatch compiler tasks on persistent domains
cknitt Sep 11, 2026
3935ebb
Record rewatch worker performance gate
cknitt Sep 11, 2026
d2a8100
Refresh Windows handoff for domain scheduler
cknitt Sep 11, 2026
9559ddc
Record repository gate after scheduler alignment
cknitt Sep 11, 2026
13927e4
Stabilize rewatch parity checks across platforms
cknitt Sep 11, 2026
daf5c64
Make rewatch interruption domain-safe
cknitt Sep 11, 2026
ebbd6dc
Poll rewatch termination from scheduler owners
cknitt Sep 11, 2026
6fe3f5a
Record cooperative interruption repository gate
cknitt Sep 11, 2026
925f833
Fix rewatch retained freshness and artifact identity
cknitt Sep 11, 2026
c1471ef
Reuse CMI publication comparisons
cknitt Sep 11, 2026
a8c1fc2
Stabilize cross-platform watcher parity tests
cknitt Sep 11, 2026
f38c4fb
Cover external rewatch diagnostics
cknitt Sep 11, 2026
50d05c5
Cache the OCaml environment for the port PR
cknitt Sep 11, 2026
6a00645
Fix relative rewatch diagnostic paths
cknitt Sep 11, 2026
f4116f4
Fix rewatch artifact and watcher edge cases
cknitt Sep 11, 2026
6dd64d9
Record the post-review rewatch quality gate
cknitt Sep 11, 2026
2760920
Stabilize configuration watcher restoration
cknitt Sep 11, 2026
30172a8
Fix rewatch warning and platform recovery
cknitt Sep 11, 2026
26da456
Simplify rewatch build state and naming
cknitt Sep 11, 2026
e991cc0
Clarify rewatch lifecycle state
cknitt Sep 11, 2026
213188f
Separate rewatch package build phases
cknitt Sep 11, 2026
5ad8b78
Narrow rewatch configuration interface duplication
cknitt Sep 11, 2026
a69c44c
Split rewatch unit tests by subsystem
cknitt Sep 11, 2026
d7a21fa
Split rewatch configuration tests by concern
cknitt Sep 11, 2026
725421a
Record rewatch cleanup review checkpoint
cknitt Sep 11, 2026
67fe50e
Remove dead rewatch interfaces and parameters
cknitt Sep 12, 2026
22437d8
Consolidate rewatch state and traversal ownership
cknitt Sep 12, 2026
1b46acc
Tighten rewatch lifecycle ownership
cknitt Sep 12, 2026
b35249a
Consolidate rewatch publication and filesystem policy
cknitt Sep 12, 2026
2559000
Split retained rewatch state from build attempts
cknitt Sep 12, 2026
147c6be
Make traversal and process probe states explicit
cknitt Sep 12, 2026
ed56fd7
Encapsulate rewatch child process ownership
cknitt Sep 12, 2026
e10ddbc
Distinguish missing rewatch paths from IO failures
cknitt Sep 12, 2026
05fc9dd
Name rewatch artifact and task records
cknitt Sep 12, 2026
9d4bab0
Own pending rewatch attempt work
cknitt Sep 12, 2026
c9d2a58
Require prepared state in rewatch build phases
cknitt Sep 12, 2026
5d4bdf2
Handle missing watched source directories
cknitt Sep 12, 2026
62f8ccc
Document rewatch release gates and handoff
cknitt Sep 12, 2026
0cf70e4
Remove temporary rewatch OPAM cache override
cknitt Sep 12, 2026
fce7413
Close rewatch setup failure paths
cknitt Sep 12, 2026
ba6bcd0
Consolidate rewatch graph and config policies
cknitt Sep 12, 2026
86b09d5
Preserve rewatch work across partial failures
cknitt Sep 12, 2026
96f33dc
Clarify rewatch graph and attempt ownership
cknitt Sep 12, 2026
d2b9cf1
Preserve rewatch recovery and scheduler invariants
cknitt Sep 12, 2026
d97e28f
Clarify rewatch package and graph ownership
cknitt Sep 12, 2026
44d133f
Split rewatch build domain state by owner
cknitt Sep 12, 2026
736c9d1
Separate rewatch scope and snapshot ownership
cknitt Sep 12, 2026
5b1935d
Narrow rewatch APIs and package visibility
cknitt Sep 12, 2026
956ef65
Model rewatch compiler source kinds explicitly
cknitt Sep 12, 2026
557cb7e
Move rewatch command logic to its owners
cknitt Sep 12, 2026
7dc51b0
Retain rewatch cycle diagnostics
cknitt Sep 12, 2026
30b8bb1
Clarify rewatch output and process tests
cknitt Sep 12, 2026
bebe7d1
Suppress external package compatibility diagnostics
cknitt Sep 12, 2026
d0f2498
Document rewatch quality and performance gates
cknitt Sep 12, 2026
cc88d13
Preserve rewatch invalidation across failures
cknitt Sep 12, 2026
40fd0f3
Preserve rewatch cleanup and namespace recovery
cknitt Sep 12, 2026
7f8bc5a
Harden rewatch cleanup and package identity
cknitt Sep 12, 2026
240ca5d
Complete rewatch watch recovery hardening
cknitt Sep 12, 2026
c833f39
Fall back when symlink watches cannot refresh
cknitt Sep 12, 2026
5319b82
Refresh rewatch artifacts after source cleanup
cknitt Sep 12, 2026
1bef3c4
Restore symlink target watch recovery
cknitt Sep 12, 2026
6fa7b11
Defer removed dependency parse invalidation
cknitt Sep 12, 2026
32bb106
Document rewatch lifecycle invariants
cknitt Sep 12, 2026
db908f3
Consolidate rewatch documentation
cknitt Sep 12, 2026
e298e49
Stabilize rewatch deletion recovery test
cknitt Sep 12, 2026
8b6e13d
Clarify deferred Windows rollout
cknitt Sep 12, 2026
27eaba4
Stabilize rewatch publication recovery tests
cknitt Sep 12, 2026
da465ae
Diagnose rewatch recovery test failures
cknitt Sep 12, 2026
c3d47b1
Trace focused rewatch CI failures
cknitt Sep 12, 2026
d8b261c
Stabilize rewatch publication fault tests
cknitt Sep 12, 2026
30e7ae0
Stabilize rewatch watcher integration tests
cknitt Sep 12, 2026
47eb5a2
Support OCaml 5.0 option APIs
cknitt Sep 12, 2026
6c5d193
Fix OCaml rewatch on Windows
cknitt Sep 12, 2026
d6d27b1
Ship OCaml rewatch on Windows
cknitt Sep 12, 2026
f494767
Validate OCaml rewatch on Windows
cknitt Sep 12, 2026
2c6a153
Match Windows interactive output
cknitt Sep 12, 2026
a4651a6
Make Windows integration coverage native
cknitt Sep 12, 2026
1fd8de5
Stabilize Windows canonical scheduling
cknitt Sep 12, 2026
bf38ef3
Keep independent Rust compiler work running
cknitt Sep 12, 2026
15bee89
Complete Windows rewatch release metadata
cknitt Sep 12, 2026
ede9af3
Address Windows adversarial review
cknitt Sep 12, 2026
97491df
Fix Windows batch execution and cancellation
cknitt Sep 12, 2026
326188f
Watch for missing nested source roots
cknitt Sep 12, 2026
f41b03d
Normalize recovering watch paths
cknitt Sep 13, 2026
0fb9498
Preserve filesystem roots in watch paths
cknitt Sep 13, 2026
859a53a
Fix build lock owner test process
cknitt Sep 13, 2026
9a5fca0
Finalize OCaml rewatch release documentation
cknitt Sep 13, 2026
c28f089
Fix command fixture paths on Bash 3
cknitt Sep 13, 2026
25cd239
Use real watcher owners in lock ordering test
cknitt Sep 13, 2026
e3db584
Recover watched symlink targets after directory renames
cknitt Sep 13, 2026
d1dadbc
Stabilize platform-specific rewatch checks
cknitt Sep 13, 2026
c484a23
Mark Windows dependency test links as directories
cknitt Sep 13, 2026
3f5c034
Reject conflicting dependency package identities
cknitt Sep 13, 2026
658b24e
Remove obsolete rewatch implementation history
cknitt Sep 13, 2026
386df09
Remove CLI oddities
cknitt Sep 13, 2026
6a7e825
Bound rewatch CI phases
cknitt Sep 13, 2026
d4383bd
Preserve root help precedence
cknitt Sep 13, 2026
aceac1c
Bound interactive rewatch CI waits
cknitt Sep 13, 2026
0d4f381
Limit interactive rewatch CI coverage
cknitt Sep 13, 2026
4bb9af6
Flush macOS interactive test output
cknitt Sep 13, 2026
3e760e5
Recognize installed rewatch launchers
cknitt Sep 13, 2026
3107609
Remove obsolete rescript-ocaml alias
cknitt Sep 13, 2026
e0df7b0
Require the Rust rewatch binary
cknitt Sep 13, 2026
8332bc1
Stabilize incremental watch output checks
cknitt Sep 13, 2026
8905b7d
Scope macOS watch output checks
cknitt Sep 13, 2026
9a14871
Report reconciled watch changes accurately
cknitt Sep 13, 2026
6efe6dc
Preserve installed rewatch launchers in integration tests
cknitt Sep 13, 2026
73e25d2
Synchronize descendant cancellation test
cknitt Sep 14, 2026
ad21eaa
Prevent intermittent OCaml CI setup failures (#8657)
cknitt Sep 14, 2026
a12512d
Make subprocess escalation authoritative
cknitt Sep 14, 2026
106ac0c
Handle completed macOS process groups
cknitt Sep 14, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
19 changes: 17 additions & 2 deletions .github/actions/setup-ocaml/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,8 @@ runs:
run: |
dependency_flags_key="${DEPENDENCY_FLAGS//--/}"
dependency_flags_key="${dependency_flags_key// /_}"
key="$CACHE_PREFIX-$OS-3.8.0-$COMPILER-$dependency_flags_key-${{ hashFiles('*.opam') }}"
dependency_hash="${{ hashFiles('*.opam', '.github/opam-repository/repo', '.github/opam-repository/packages/**') }}"
key="$CACHE_PREFIX-$OS-3.8.0-$COMPILER-$dependency_flags_key-$dependency_hash"
echo "value=${key//,/-}" >> "$GITHUB_OUTPUT"
echo "setup-version=3.8.0" >> "$GITHUB_OUTPUT"

Expand All @@ -104,6 +105,11 @@ runs:
uses: ocaml/setup-ocaml@v3.8.0
with:
ocaml-compiler: ${{ inputs.compiler }}
# Use the HTTP repository to prevent intermittent CI setup failures:
# the Git-backed default can race with detached Git maintenance while
# OPAM scans it (https://github.com/ocaml/opam/issues/7031).
opam-repositories: |
default: https://opam.ocaml.org
opam-pin: false
cache: false

Expand All @@ -125,12 +131,21 @@ runs:
env:
DEPENDENCY_FLAGS: ${{ inputs.dependency-flags }}
run: |
opam repository add rescript-overrides "$GITHUB_WORKSPACE/.github/opam-repository"
read -ra dependency_flags <<< "$DEPENDENCY_FLAGS"
if [[ "$RUNNER_OS" == "Windows" ]]; then
export AR=x86_64-w64-mingw32-ar
export RANLIB=x86_64-w64-mingw32-ranlib
export STRIP=x86_64-w64-mingw32-strip
export NM=x86_64-w64-mingw32-nm
export DLLTOOL=x86_64-w64-mingw32-dlltool
export OBJDUMP=x86_64-w64-mingw32-objdump
fi
opam install . "${dependency_flags[@]}"

- name: Cache OPAM environment
# Caches created by pull_request runs are scoped to that PR's merge ref
# and cannot seed other PRs or branches. Only pushes create shared caches.
# and cannot seed other PRs or branches, so only push runs save them.
if: steps.cache.outputs.cache-hit != 'true' && github.event_name == 'push'
uses: actions/cache/save@v6
with:
Expand Down
14 changes: 14 additions & 0 deletions .github/opam-repository/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
# ReScript opam overrides

This repository contains narrowly scoped dependency fixes needed by CI before
they are available from the main opam repository.

The Luv 0.5.14 override preserves the ARM64 musl compiler's
`-mno-outline-atomics` requirement while building vendored libuv. Without it,
the static executable fails to link because libuv refers to glibc's internal
`__getauxval` symbol. The patch should be contributed upstream and this
override removed once a fixed Luv release is available.

Luv 0.5.14 also vendors libuv 1.48.0. Evaluating and contributing an update to
a current libuv 1.x release is a separate upstream follow-up; changing the
vendored library is intentionally outside the OCaml rewatch port.
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
--- a/src/c/dune
+++ b/src/c/dune
@@ -82,8 +82,14 @@
(action (progn
(bash "cp -r vendor/configure/* vendor/libuv/")
(chdir vendor/libuv (progn
(bash
- "sh configure --host `ocamlc -config | awk '/^host:/ {print $NF}'` \
- 'CC=%{cc}' CFLAGS=-DNDEBUG --silent --enable-silent-rules")
+ "architecture=`ocamlc -config-var architecture`
+ c_compiler=`ocamlc -config-var c_compiler`
+ extra_cflags=
+ case \"$architecture:$c_compiler\" in
+ arm64:*musl*) extra_cflags=-mno-outline-atomics ;;
+ esac
+ sh configure --host `ocamlc -config | awk '/^host:/ {print $NF}'` \
+ 'CC=%{cc}' CFLAGS=\"-DNDEBUG $extra_cflags\" --silent --enable-silent-rules")
(ignore-outputs (bash
"$([ '%{os_type}' = Unix ] && echo %{make} || echo make) V=0 -j 4 \
-o aclocal.m4 -o Makefile.in -o configure \
42 changes: 42 additions & 0 deletions .github/opam-repository/packages/luv/luv.0.5.14/opam
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
opam-version: "2.0"
name: "luv"
version: "0.5.14"
synopsis: "Binding to libuv: cross-platform asynchronous I/O"
description: """\
Luv is a binding to libuv, the cross-platform C library that does
asynchronous I/O in Node.js and runs its main loop.

Besides asynchronous I/O, libuv also supports multiprocessing and
multithreading. Multiple event loops can be run in different threads. libuv also
exposes a lot of other functionality, amounting to a full OS API, and an
alternative to the standard module Unix."""
maintainer: "Anton Bachin <antonbachin@yahoo.com>"
authors: "Anton Bachin <antonbachin@yahoo.com>"
license: "MIT"
homepage: "https://github.com/aantron/luv"
doc: "https://aantron.github.io/luv"
bug-reports: "https://github.com/aantron/luv/issues"
depends: [
"base-unix" {build}
"ctypes" {>= "0.14.0"}
"dune" {>= "2.7.0"}
"ocaml" {>= "4.03.0"}
"alcotest" {with-test & >= "0.8.1"}
"base-unix" {with-test}
"odoc" {with-doc & = "2.4.0"}
]
build: ["dune" "build" "-p" name "-j" jobs]
patches: ["arm64-musl-outline-atomics.patch"]
extra-files: [
[
"arm64-musl-outline-atomics.patch"
"sha256=c15c4c4d34c9b545197c5160e19c69a128cc186b65a54e0e9a779c2543528a4f"
]
]
dev-repo: "git+https://github.com/aantron/luv.git"
url {
src:
"https://github.com/aantron/luv/releases/download/0.5.14/luv-0.5.14.tar.gz"
checksum:
"sha256=8e01b4a50c8876cdd98d8e245c0687c4dc4d883aed161ad9c5ace1fb1fdaae99"
}
1 change: 1 addition & 0 deletions .github/opam-repository/repo
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
opam-version: "2.0"
65 changes: 61 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ jobs:
with:
compiler: ${{ matrix.ocaml_compiler }}
os: ${{ matrix.os }}
cache-prefix: opam-env-v8
cache-prefix: opam-env-v9

- name: Compiler build state key
id: compiler-build-state-key
Expand Down Expand Up @@ -212,8 +212,61 @@ jobs:
run: echo "C:\Program Files\Git\bin" >> $GITHUB_PATH
shell: bash

- name: Run rewatch tests
run: ./rewatch/tests/suite.sh rewatch/target/release/rescript
- name: Run OCaml rewatch parity tests
timeout-minutes: 20
run: |
bash rewatch-ocaml/tests/check_rust_test_coverage.sh --require-complete
bash rewatch-ocaml/tests/check_canonical_test_coverage.sh
bash rewatch-ocaml/tests/check_config_acceptance.sh \
packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
bash rewatch-ocaml/tests/check_command_validation.sh \
packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
shell: bash

- name: Run OCaml rewatch interactive output tests
# Terminal rendering depends on the host OS, not the CPU architecture.
# Use the faster ARM runners for one Linux and one macOS check. Windows
# does not provide a reliable native equivalent of the `script` PTY.
if: matrix.node-target == 'linux-arm64' || matrix.node-target == 'darwin-arm64'
timeout-minutes: 15
run: |
bash rewatch-ocaml/tests/check_interactive_output.sh \
packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
shell: bash

- name: Run OCaml rewatch verbose output tests
timeout-minutes: 10
run: |
bash rewatch-ocaml/tests/check_verbose_output.sh \
packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
shell: bash

- name: Run OCaml rewatch unit tests
timeout-minutes: 10
run: |
opam exec -- dune build tests/rewatch_ounit_tests/rewatch_ounit_tests_main.exe
# Run the executable directly so a stuck test leaves live progress;
# dune otherwise buffers the test output until the action exits.
opam exec -- ./_build/default/tests/rewatch_ounit_tests/rewatch_ounit_tests_main.exe -runner sequential
shell: bash

- name: Run OCaml rewatch focused integration tests
timeout-minutes: 30
run: |
sh rewatch-ocaml/tests/run.sh packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
shell: bash

- name: Run OCaml rewatch canonical tests
run: ./rewatch/tests/suite.sh packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
shell: bash

- name: Run Rust rewatch reference tests on Windows
if: runner.os == 'Windows'
run: ./rewatch/tests/suite.sh packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe
shell: bash

- name: Run syntax benchmarks
Expand Down Expand Up @@ -623,6 +676,10 @@ jobs:
shell: bash
working-directory: rewatch/testrepo

- name: Run rewatch integration tests
- name: Run installed default OCaml rewatch integration tests
run: ./rewatch/tests/suite.sh rewatch/testrepo/node_modules/.bin/rescript
shell: bash

- name: Run installed Rust rewatch reference integration tests
run: ./rewatch/tests/suite.sh rewatch/testrepo/node_modules/.bin/rescript-rust
shell: bash
2 changes: 1 addition & 1 deletion .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ jobs:
with:
compiler: ${{ env.OCAML_COMPILER }}
os: ${{ env.OS }}
cache-prefix: opam-coverage-v1
cache-prefix: opam-coverage-v2
dependency-flags: --deps-only --with-test --with-dev-setup

- name: Install OCaml coverage tooling
Expand Down
20 changes: 13 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,8 @@ $(YARN_INSTALL_STAMP): $(YARN_INSTALL_SOURCES)

REWATCH_SOURCES = $(shell find rewatch/src -name '*.rs') rewatch/Cargo.toml rewatch/Cargo.lock rewatch/rust-toolchain.toml
RESCRIPT_EXE = $(BIN_DIR)/rescript.exe
RESCRIPT_RUST_EXE := $(BIN_DIR)/rescript-rust.exe
PACKAGED_RUST_EXE := $(RESCRIPT_RUST_EXE)
ifdef CI
REWATCH_PROFILE := release
REWATCH_CARGO_FLAGS := --release
Expand All @@ -88,22 +90,22 @@ else
endif
REWATCH_TARGET := rewatch/target/$(REWATCH_PROFILE)/rescript$(PLATFORM_EXE_EXT)

rewatch: $(RESCRIPT_EXE)
rewatch: $(PACKAGED_RUST_EXE)

$(RESCRIPT_EXE): $(REWATCH_TARGET)
$(PACKAGED_RUST_EXE): $(REWATCH_TARGET)
$(call COPY_EXE,$<,$@)

$(REWATCH_TARGET): $(REWATCH_SOURCES)
cargo build --manifest-path rewatch/Cargo.toml $(REWATCH_CARGO_FLAGS)

clean-rewatch:
cargo clean --manifest-path rewatch/Cargo.toml && rm -rf rewatch/target && rm -f $(RESCRIPT_EXE)
cargo clean --manifest-path rewatch/Cargo.toml && rm -rf rewatch/target && rm -f $(PACKAGED_RUST_EXE)

# Compiler

COMPILER_SOURCE_DIRS := compiler tests analysis tools
COMPILER_SOURCES = $(shell find $(COMPILER_SOURCE_DIRS) -type f \( -name '*.ml' -o -name '*.mli' -o -name '*.dune' -o -name dune -o -name dune-project \))
COMPILER_BIN_NAMES := bsc rescript-editor-analysis rescript-tools
COMPILER_SOURCE_DIRS := compiler tests analysis tools rewatch-ocaml
COMPILER_SOURCES = $(shell find $(COMPILER_SOURCE_DIRS) -type f \( -name '*.ml' -o -name '*.mli' -o -name '*.c' -o -name '*.h' -o -name '*.dune' -o -name dune -o -name dune-project \))
COMPILER_BIN_NAMES := bsc rescript-editor-analysis rescript-tools rescript
COMPILER_EXES := $(addsuffix .exe,$(addprefix $(BIN_DIR)/,$(COMPILER_BIN_NAMES)))

compiler: $(COMPILER_EXES)
Expand Down Expand Up @@ -279,9 +281,13 @@ COVERAGE_TEST_ENV := BISECT_FILE=$(COVERAGE_BISECT_PREFIX) BISECT_SILENT=YES
.PHONY: coverage-build
coverage-build: | $(YARN_INSTALL_STAMP)
dune build --instrument-with bisect_ppx
@$(foreach bin,$(COMPILER_BIN_NAMES), \
@$(foreach bin,$(filter-out rescript,$(COMPILER_BIN_NAMES)), \
cp $(DUNE_BIN_DIR)/$(bin)$(PLATFORM_EXE_EXT) $(BIN_DIR)/$(bin).exe && \
chmod 755 $(BIN_DIR)/$(bin).exe;)
ifneq ($(OS),Windows_NT)
cp _build/default/rewatch-ocaml/rescript_ocaml.exe $(RESCRIPT_EXE)
chmod 755 $(RESCRIPT_EXE)
endif

.PHONY: coverage-prepare
coverage-prepare: clean-coverage coverage-build
Expand Down
Loading
Loading