Adapt to Coq/Coq#18164 #7
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Docker CI | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- '**' | |
jobs: | |
build: | |
# the OS must be GNU/Linux to be able to use the docker-coq-action | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
coq: | |
- '8.9' | |
- '8.11' | |
- '8.12' | |
- '8.13' | |
- '8.14' | |
- '8.15' | |
- '8.16' | |
- '8.17' | |
- 'dev' | |
fail-fast: false | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- uses: coq-community/docker-coq-action@v1 | |
with: | |
opam_file: 'coq-ext-lib.opam' | |
coq_version: ${{ matrix.coq }} | |
before_script: | | |
startGroup "Workaround permission issue" | |
sudo chown -R coq:coq . | |
endGroup | |
after_script: | | |
set -o pipefail # recommended if the script uses pipes | |
startGroup "Generate Coqdoc" | |
make -j`nproc` html | |
endGroup | |
startGroup "Test dependants" | |
opam install conf-clang | |
PINS=$(opam list -s --pinned --columns=package | xargs | tr ' ' ,) | |
PACKAGES=`opam list -s --depends-on coq-ext-lib --coinstallable-with $PINS` | |
for PACKAGE in $PACKAGES | |
do DEPS_FAILED=false | |
opam install --deps-only $PACKAGE || DEPS_FAILED=true | |
[ $DEPS_FAILED == true ] || opam install -t $PACKAGE | |
done | |
endGroup | |
export: 'OPAMWITHTEST OPAMCONFIRMLEVEL' | |
env: | |
OPAMWITHTEST: true | |
OPAMCONFIRMLEVEL: unsafe-yes | |
- name: Revert permissions | |
# to avoid a warning at cleanup time | |
if: ${{ always() }} | |
run: sudo chown -R 1001:116 . | |
- uses: actions/upload-artifact@v3 | |
with: | |
name: coqdoc | |
path: html | |
# See also: | |
# https://github.com/coq-community/docker-coq-action#readme | |
# https://github.com/erikmd/docker-coq-github-action-demo |