Skip to content

Commit

Permalink
Adding OCaml 5.2 to CI
Browse files Browse the repository at this point in the history
Signed-off-by: Kakadu <[email protected]>
  • Loading branch information
Kakadu committed Jul 30, 2024
1 parent 2435ea8 commit 607b43a
Show file tree
Hide file tree
Showing 4 changed files with 104 additions and 7 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/master.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
name: Build master in docker

on:
pull_request:
branches:
- 'master'
# pull_request:
# branches:
# - 'master'
push:
branches:
- 'master'
Expand Down
93 changes: 93 additions & 0 deletions .github/workflows/master52.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
name: Build master in docker (OCaml 5.2)

on:
# pull_request:
# branches:
# - 'master'
push:
branches:
- 'master'
paths-ignore:
- 'README.md'

env:
OPAMROOT: /home/opam/.opam
OPAMCONFIRMLEVEL: unsafe-yes
GT_WITH_DOCS: yes

jobs:
build:
strategy:
fail-fast: false
matrix:
os:
- ubuntu-latest

runs-on: ${{ matrix.os }}
container:
image: ocaml/opam:ubuntu-lts-ocaml-5.2
options: --user root # dirty hack

steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}

- name: Checkout code
uses: actions/checkout@v4

- run: sudo apt-get update
- run: opam --version

- name: Update submodules
if: false
run: |
git config --global --add safe.directory /__w/GT/GT
git submodule update --init
- run: opam pin add GT . --no-action
if: false

- run: opam depext GT --yes #--with-test
if: false

- name: Install dependecies for documentation
if: false
run: |
sudo apt-get install pkg-config libpcre2-dev -y
#opam install odoc pa_ppx --yes --depext
opam install odoc pa_ppx --yes
- run: opam install . --deps-only --with-test --with-doc
- run: opam exec -- dune build --profile=release
- run: opam exec -- dune test --profile=release

- name: Build documentation
run: opam exec -- dune build -p GT @doc

- name: Installing using Opam
run: |
opam exec -- dune build @install
opam exec -- dune install
- name: List files
run: opam show --list-files GT

# disabled, because we will do a deploy from OCaml 4.14
# - name: Deploy documentation
# if: ${{ github.event.pull_request.head.repo.full_name == 'PLTools/OCanren' }}
# uses: peaceiris/actions-gh-pages@v3
# with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
# publish_dir: ./_build/default/_doc/_html

# - name: Send coverage report to Coveralls
# run: |
# #git config --global --add safe.directory /__w/zanuda/zanuda
# opam exec -- make coverage
# opam exec -- bisect-ppx-report send-to Coveralls --coverage-path $BISECT_DIR
# env:
# BISECT_DIR: /tmp/GTcov
# COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }}
# PULL_REQUEST_NUMBER: ${{ github.event.number }}
6 changes: 4 additions & 2 deletions GT.opam
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,14 @@ depends: [
"ocaml" {>= "4.13" & < "5.0.0" | >= "5.2.0" & < "5.3.0"}
"camlp5" {>= "8.00.05"}
"dune" {>= "2.8"}
"ocamlgraph"
"ppx_inline_test"
"ocamlfind" {build}
"logger-p5" {build}
"bisect_ppx" {build}
"conf-m4" {build}
"ocamlgraph"
"ppx_inline_test"
"doc" {with-doc}
"odig" {with-doc}
"odoc" {with-doc}
]
build: [
Expand Down
6 changes: 4 additions & 2 deletions dune-project
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,14 @@
(camlp5
(>= "8.00.05"))
dune
ocamlgraph
ppx_inline_test
(ocamlfind :build)
(logger-p5 :build)
(bisect_ppx :build)
(conf-m4 :build)
ocamlgraph
ppx_inline_test
(doc :with-doc)
(odig :with-doc)
;
))

Expand Down

0 comments on commit 607b43a

Please sign in to comment.