From 400eb4f5fd60a494376648b2f7b12cd51bded207 Mon Sep 17 00:00:00 2001 From: "Haochen M. Kotoi-Xie" Date: Sat, 16 Sep 2023 00:10:22 +0900 Subject: [PATCH] ocaml-general - add ocaml.5.1.0 --- .github/workflows/ocaml-general.yml | 5 +-- ...ages.sh => install_ocaml_4.13_packages.sh} | 0 ...kages.sh => install_ocaml_5.0_packages.sh} | 0 ocaml-general/install_ocaml_5.1_packages.sh | 31 +++++++++++++++++++ 4 files changed, 34 insertions(+), 2 deletions(-) rename ocaml-general/{install_ocaml_4_packages.sh => install_ocaml_4.13_packages.sh} (100%) rename ocaml-general/{install_ocaml_5_packages.sh => install_ocaml_5.0_packages.sh} (100%) create mode 100755 ocaml-general/install_ocaml_5.1_packages.sh diff --git a/.github/workflows/ocaml-general.yml b/.github/workflows/ocaml-general.yml index 115c940..7b8c284 100644 --- a/.github/workflows/ocaml-general.yml +++ b/.github/workflows/ocaml-general.yml @@ -30,6 +30,7 @@ jobs: ocaml-version: - 4.13.1 - 5.0.0 + - 5.1.0 arch: - amd64 # - arm64 # it's taking too long for the purpose of validation @@ -47,7 +48,7 @@ jobs: - uses: actions/checkout@v3 - name: Set up env var - run: echo "PACKAGE_INSTALL_SCRIPT_FILENAME=install_ocaml_$(eval cut -d'.' -f1 <<< ${{ matrix.ocaml-version }})_packages.sh" | tee -a $GITHUB_ENV + run: echo "PACKAGE_INSTALL_SCRIPT_FILENAME=install_ocaml_$(eval cut -d'.' -f1-2-2 <<< ${{ matrix.ocaml-version }})_packages.sh" | tee -a $GITHUB_ENV - name: Set up QEMU for arm64 uses: docker/setup-qemu-action@v2 @@ -126,7 +127,7 @@ jobs: - name: Set up env var run: | - echo "PACKAGE_INSTALL_SCRIPT_FILENAME=install_ocaml_$(eval cut -d'.' -f1 <<< ${{ matrix.ocaml-version }})_packages.sh" | tee -a $GITHUB_ENV + echo "PACKAGE_INSTALL_SCRIPT_FILENAME=install_ocaml_$(eval cut -d'.' -f1-2 <<< ${{ matrix.ocaml-version }})_packages.sh" | tee -a $GITHUB_ENV echo "DOCKER_TAG_LIST=${{ env.PACKAGE_NAME }}:${{ env.DOCKER_TAG }},${{ env.PACKAGE_NAME }}:${{ env.DOCKER_TAG }}-${{ github.sha }}" | tee -a $GITHUB_ENV | tr '=,' '\n' | sort - name: Set up env var for alias (node hydrogen && arch amd64) diff --git a/ocaml-general/install_ocaml_4_packages.sh b/ocaml-general/install_ocaml_4.13_packages.sh similarity index 100% rename from ocaml-general/install_ocaml_4_packages.sh rename to ocaml-general/install_ocaml_4.13_packages.sh diff --git a/ocaml-general/install_ocaml_5_packages.sh b/ocaml-general/install_ocaml_5.0_packages.sh similarity index 100% rename from ocaml-general/install_ocaml_5_packages.sh rename to ocaml-general/install_ocaml_5.0_packages.sh diff --git a/ocaml-general/install_ocaml_5.1_packages.sh b/ocaml-general/install_ocaml_5.1_packages.sh new file mode 100755 index 0000000..b91e0d2 --- /dev/null +++ b/ocaml-general/install_ocaml_5.1_packages.sh @@ -0,0 +1,31 @@ +#!/bin/bash -xe + +packages=( + dune.3.10.0 + merlin + odoc.2.2.1 + ppxlib.0.30.0 + bisect_ppx.2.8.3 + ppx_deriving.5.2.1 + js_of_ocaml.5.4.0 js_of_ocaml-ppx.5.4.0 js_of_ocaml-lwt.5.4.0 + jsonm.1.0.1 + ezjsonm.1.3.0 + ppx_optcomp.v0.16.0 + brr.0.0.4 + prr.0.1.1 + zed.3.2.0 + ppx_inline_test.v0.16.0 + alcotest.1.7.0 + qcheck.0.21.2 + qcheck-alcotest.0.21.2 + sexplib.v0.16.0 ppx_sexp_conv.v0.16.0 + yojson.2.1.0 ppx_yojson_conv.v0.16.0 + tezt.3.1.1 +) + +opam install --yes "${packages[@]}" \ + && opam clean -y --logs --repo-cache --download-cache --switch-cleanup + +echo -n "exec: " +printf "%s\n" "${packages[@]}" | cut -d'.' -f1 | xargs echo opam show -f package +printf "%s\n" "${packages[@]}" | cut -d'.' -f1 | xargs opam show -f package