From a3f27bd3cbf03d5e02137ed0bdd9cec91f1e075f Mon Sep 17 00:00:00 2001 From: Sora Morimoto Date: Tue, 19 Apr 2022 11:42:02 +0900 Subject: [PATCH] Update GitHub Actions workflows Signed-off-by: Sora Morimoto --- .github/workflows/gh-pages.yml | 40 ++++++++++------------------------ .github/workflows/main.yml | 4 ++-- .gitignore | 1 + 3 files changed, 14 insertions(+), 31 deletions(-) diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml index 71d4402a..e2af947d 100644 --- a/.github/workflows/gh-pages.yml +++ b/.github/workflows/gh-pages.yml @@ -3,41 +3,23 @@ name: github pages on: push: branches: - - master # Set a branch name to trigger deployment + - master jobs: deploy: runs-on: ubuntu-latest steps: - - uses: actions/checkout@main + - name: Checkout code + uses: actions/checkout@v3 - - name: Cache opam - id: cache-opam - uses: actions/cache@v2 + - name: Use OCaml 4.14.x + uses: ocaml/setup-ocaml@v2 with: - path: ~/.opam - key: opam-ubuntu-latest-4.12.0 + ocaml-compiler: 4.14.x + dune-cache: true - - uses: avsm/setup-ocaml@v1 + - name: Deploy odoc to GitHub Pages + uses: ocaml/setup-ocaml/deploy-doc@v2 with: - ocaml-version: '4.12.0' - - - name: Pin - run: opam pin -n . - - - name: Depext - run: opam depext -yt tiny_httpd tiny_httpd_camlzip - - - name: Deps - run: opam install -d . --deps-only - - - name: Build - run: opam exec -- dune build @doc - - - name: Deploy - uses: peaceiris/actions-gh-pages@v3 - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./_build/default/_doc/_html/ - destination_dir: dev - enable_jekyll: true + destination-dir: dev + enable-jekyll: true diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 906464eb..78613ae8 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -18,13 +18,13 @@ jobs: - windows-latest ocaml-compiler: - 4.04.x - - 4.13.x + - 4.14.x runs-on: ${{ matrix.os }} steps: - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Use OCaml ${{ matrix.ocaml-compiler }} uses: ocaml/setup-ocaml@v2 diff --git a/.gitignore b/.gitignore index f6d0aa3d..3a62426b 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ .git _build +_opam *.install .merlin