Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use ocaml/setup-ocaml@v2 #1324

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 5 additions & 16 deletions .github/workflows/saw-core-coq-check-coq-files.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,25 +20,15 @@ jobs:
env:
COQ_VERSION: ${{ matrix.coq }}
# coq-bits claims to support < 4.10 only
OCAML_VERSION: 4.09.1
OCAML_VERSION: 4.09.x
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This allows you to always use the latest point release.

COQBITS_VERSION: 1.0.0
steps:

- uses: actions/checkout@v2

- name: Cache ~/.opam
uses: actions/cache@v2
with:
path: ~/.opam
key: opam-${{ runner.os }}-${{ env.OCAML_VERSION }}-${{ env.COQ_VERSION }}-${{ env.COQBITS_VERSION }}

# NOTE: this action is marked as experimental by their author, but it is
# much faster than avsm@setup-ocaml@v1. However, if this one ever becomes
# problematic, it should suffice to switch back to that version.
- name: Set up ocaml and opam
uses: actions-ml/setup-ocaml@df8c831c6c1e49804621d6e09c4ab9235da31fb5
uses: ocaml/setup-ocaml@v2
with:
ocaml-version: ${{ env.OCAML_VERSION }}
ocaml-compiler: ${{ env.OCAML_VERSION }}

- name: Install coq
shell: bash
Expand All @@ -56,6 +46,5 @@ jobs:
shell: bash
working-directory: saw-core-coq/coq
run: |
eval $(opam env)
coq_makefile -f _CoqProject -o Makefile.coq
make -j2
opam exec -- coq_makefile -f _CoqProject -o Makefile.coq
opam exec -- make -j2
Comment on lines -59 to +50
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's recommended to use opam exec instead of eval $(opam env).