Skip to content
Draft
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
2 changes: 1 addition & 1 deletion .github/workflows/esy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Esy
on:
push:
branches: [main]
pull_request:
# pull_request:

# This will cancel previous runs when a branch or PR is updated
concurrency:
Expand Down
41 changes: 26 additions & 15 deletions .github/workflows/opam.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
ocaml-compiler: [4.14.1, 5.3.0]
ocaml-compiler: [5.3.0]

steps:
- name: Setup node.js
Expand All @@ -32,29 +32,40 @@ jobs:
with:
submodules: true

# We use esy-bash as a build environment to keep the cygwin environment the same as esy
- name: Checkout esy-bash
uses: actions/checkout@v4
with:
repository: esy/esy-bash
path: .tools/esy-bash

- name: Setup esy-bash environment
working-directory: .tools/esy-bash
run: |
npm i -g esy@0.9.2
npm install
npm run build-exe
npm run build-cygwin
npm link

- name: Setup OCaml ${{ matrix.ocaml-compiler }}
uses: ocaml/setup-ocaml@4dd53a587b9836a35604fec9601e606ff42145bc # v3.4.1
uses: ocaml/setup-ocaml@93303b622b2522e4411e295f9e77411a24912ac7 # v3.9.0
with:
ocaml-compiler: ${{ matrix.ocaml-compiler }}

- name: Inspect depexts
run: |
opam exec -- which cmake
opam exec -- which gcc
opam exec -- which g++
opam exec -- gcc --version
opam exec -- g++ --version
esy-bash opam exec -- which cmake
esy-bash opam exec -- which gcc
esy-bash opam exec -- which g++
esy-bash opam exec -- gcc --version
esy-bash opam exec -- g++ --version

- name: Install local dependencies
run: opam install . --deps-only --with-test

# Cygwin's cmake hangs during compiler detection with libuv1 1.53.0
- name: Pin Cygwin libuv1
if: runner.os == 'Windows'
run: Start-Process -Wait -NoNewWindow D:\.opam\.cygwin\setup-x86_64.exe '-q -R D:\cygwin -P libuv1=1.52.1-1'
run: esy-bash opam install . --deps-only --with-test

- name: Build project
run: opam exec -- dune build
run: esy-bash opam exec -- dune build

- name: Run tests
run: opam exec -- dune runtest --display=short
run: esy-bash opam exec -- dune runtest --display=short
Loading