diff --git a/.github/workflows/workflow.yml b/.github/workflows/workflow.yml index 9c8145ceb..6ace2aee0 100644 --- a/.github/workflows/workflow.yml +++ b/.github/workflows/workflow.yml @@ -1,24 +1,26 @@ -name: Main workflow +name: Builds, tests & co on: - pull_request: push: + pull_request: schedule: # Prime the caches every Monday - cron: 0 1 * * MON +permissions: read-all + jobs: build: strategy: fail-fast: false matrix: os: - - macos-latest - ubuntu-latest + - macos-latest - windows-latest ocaml-compiler: - - "4.14" - - "5.2" + - 5 + - 4 include: - os: ubuntu-latest ocaml-compiler: "4.08" @@ -40,10 +42,51 @@ jobs: uses: ocaml/setup-ocaml@v3 with: ocaml-compiler: ${{ matrix.ocaml-compiler }} - opam-pin: false - run: opam install . --deps-only - run: opam exec -- bash ./configure - run: opam exec -- make all + + # lint-doc: + # runs-on: ubuntu-latest + # steps: + # - name: Checkout tree + # uses: actions/checkout@v4 + # - name: Set-up OCaml + # uses: ocaml/setup-ocaml@v3 + # with: + # ocaml-compiler: 5 + # - run: opam install . --deps-only + # - run: opam exec -- bash ./configure + # - run: opam exec -- make all + # - uses: ocaml/setup-ocaml/lint-doc@v3 + + lint-fmt: + runs-on: ubuntu-latest + steps: + - name: Checkout tree + uses: actions/checkout@v4 + - name: Set-up OCaml + uses: ocaml/setup-ocaml@v3 + with: + ocaml-compiler: 5 + - run: opam install . --deps-only + - run: opam exec -- bash ./configure + - run: opam exec -- make all + - uses: ocaml/setup-ocaml/lint-fmt@v3 + + # lint-opam: + # runs-on: ubuntu-latest + # steps: + # - name: Checkout tree + # uses: actions/checkout@v4 + # - name: Set-up OCaml + # uses: ocaml/setup-ocaml@v3 + # with: + # ocaml-compiler: 5 + # - run: opam install . --deps-only + # - run: opam exec -- bash ./configure + # - run: opam exec -- make all + # - uses: ocaml/setup-ocaml/lint-opam@v3 diff --git a/.ocamlformat-ignore b/.ocamlformat-ignore new file mode 100644 index 000000000..525cbbdcb --- /dev/null +++ b/.ocamlformat-ignore @@ -0,0 +1 @@ +src/baselib/ocsigen_config_static.ml diff --git a/src/baselib/dune b/src/baselib/dune index f24d9d7ff..37d2e2281 100644 --- a/src/baselib/dune +++ b/src/baselib/dune @@ -12,8 +12,13 @@ (wrapped false) (flags (:standard -no-keep-locs)) - (modules dynlink_wrapper ocsigen_cache ocsigen_config_static ocsigen_lib - ocsigen_loader ocsigen_stream) + (modules + dynlink_wrapper + ocsigen_cache + ocsigen_config_static + ocsigen_lib + ocsigen_loader + ocsigen_stream) (libraries str findlib diff --git a/src/server/dune b/src/server/dune index 602b9199f..972a0bee9 100644 --- a/src/server/dune +++ b/src/server/dune @@ -2,5 +2,10 @@ (name ocsigenserver) (public_name ocsigenserver) (wrapped false) - (libraries xml-light cohttp-lwt-unix polytables ocsigen_cookie_map baselib - http)) + (libraries + xml-light + cohttp-lwt-unix + polytables + ocsigen_cookie_map + baselib + http))