Skip to content

Commit

Permalink
Merge pull request #4 from aryx/gha_matrix
Browse files Browse the repository at this point in the history
gha: try compilation matrix
  • Loading branch information
aryx authored Apr 19, 2024
2 parents 582403c + de44cf3 commit 069a285
Show file tree
Hide file tree
Showing 3 changed files with 33 additions and 20 deletions.
34 changes: 19 additions & 15 deletions .github/workflows/build-and-test.jsonnet
Original file line number Diff line number Diff line change
Expand Up @@ -13,26 +13,30 @@ local checkout = {
// ----------------------------------------------------------------------------

local job = {
// LATER:
// strategy:
// fail-fast: false
// matrix:
// os:
// - macos-latest
// - ubuntu-latest
// - windows-latest
// ocaml-compiler:
// - "5.1"
//
// runs-on: ${{ matrix.os }}
'runs-on': 'ubuntu-latest',
strategy: {
//'fail-fast': false,
matrix: {
os: [
'ubuntu-latest',
//TODO: 'macos-latest'
//TODO: 'windows-latest'
],
'ocaml-compiler': [
// Old version with |> builtin but ideally we would like even before
'4.02.1',
// first version with valid ocamlformat
'4.04.1',
//TODO: 3.10.0, but pb with |>
],
}
},
'runs-on': '${{ matrix.os }}',
steps: [
checkout,
{
uses: "ocaml/setup-ocaml@v2",
with: {
// TODO: ${{ matrix.ocaml-compiler }}
'ocaml-compiler': "4.02.1",
'ocaml-compiler': '${{ matrix.ocaml-compiler }}',
}
},
{
Expand Down
11 changes: 9 additions & 2 deletions .github/workflows/build-and-test.yml
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
# AUTOGENERATED FROM build-and-test.jsonnet DO NOT MODIFY
jobs:
job:
runs-on: ubuntu-latest
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v3
- uses: ocaml/setup-ocaml@v2
with:
ocaml-compiler: 4.02.1
ocaml-compiler: ${{ matrix.ocaml-compiler }}
- name: Install dependencies
run: |
echo No dependencies! This is xix! It does not need anything!
Expand All @@ -17,6 +17,13 @@ jobs:
- name: Basic test
run: |
./test.sh
strategy:
matrix:
ocaml-compiler:
- 4.02.1
- 4.04.1
os:
- ubuntu-latest
name: build-and-test
on:
pull_request: null
Expand Down
8 changes: 5 additions & 3 deletions changes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@
# the birth of Nathalie, and especially my work for Semgrep.

** devops
Add Github actions (GHA) checks to make sure xix compiles,
at least compiles with 4.02.1 (use of |> so harder to compile
Github actions (GHA) checks to make sure xix compiles.
At least it compiles with 4.02.1 (use of |> so harder to compile
for 3.10.0).

Added some basic tests (also enforced in GHA).
First semgrep checks in semgrep.jsonnet :)

Some basic tests (also enforced in GHA) in test.sh

* -----------------------------------------------------------

Expand Down

0 comments on commit 069a285

Please sign in to comment.