-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
16 additions
and
16 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,11 +36,11 @@ jobs: | |
packages: read | ||
contents: write | ||
steps: | ||
- name: get number of CPU cores | ||
- name: Get number of CPU cores | ||
uses: SimenB/github-actions-cpu-cores@v2 | ||
id: cpu-cores | ||
|
||
- name: repo checkout | ||
- name: Checkout repo | ||
uses: actions/checkout@v4 | ||
|
||
- name: Initialise variables | ||
|
@@ -52,17 +52,17 @@ jobs: | |
echo "DOC_DEPLOY=false" >> $GITHUB_ENV | ||
fi | ||
- name: container registry log in | ||
- name: Log in container registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ${{ env.REGISTRY }} | ||
username: ${{ github.actor }} | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: image pre-pulling | ||
- name: Pre-pull docker image | ||
run: docker pull ${{ env.REGISTRY }}/${{ env.IMAGE_TAG }} | ||
|
||
- name: coq processing | ||
- name: Process main steps | ||
uses: coq-community/docker-coq-action@v1 | ||
with: | ||
custom_image: ${{ env.REGISTRY }}/${{ env.IMAGE_TAG }} | ||
|
@@ -78,6 +78,15 @@ jobs: | |
make coqdoc | ||
fi | ||
endGroup | ||
startGroup "Build HTMLs for GitHub pages" | ||
if [[ "${{ env.DOC_DEPLOY }}" == 'true' ]]; then | ||
make coqdoc | ||
mv theories/html html | ||
cp assets/styling.css html/styling.css | ||
cp -r assets/images html/images | ||
pandoc README.md -H assets/include.html --no-highlight --metadata pagetitle='McLTT: A Bottom-up Approach to Implementing A Proof Assistant' -t html --css styling.css -o html/index.html | ||
fi | ||
endGroup | ||
startGroup "Run inline tests" | ||
dune runtest | ||
endGroup | ||
|
@@ -89,21 +98,12 @@ jobs: | |
OPAMJOBS: ${{ steps.cpu-cores.outputs.count }} | ||
OPAMYES: "true" | ||
|
||
- name: permissions revert | ||
- name: Revert permissions | ||
# to avoid a warning at cleanup time | ||
if: ${{ always() }} | ||
run: sudo chown -R 1001:116 . | ||
|
||
- name: generate Github pages | ||
if: ${{ success() && env.DOC_DEPLOY == 'true' }} | ||
run: | | ||
sudo apt install -y pandoc | ||
mv theories/html html | ||
cp assets/styling.css html/styling.css | ||
cp -r assets/images html/images | ||
pandoc README.md -H assets/include.html --no-highlight --metadata pagetitle='McLTT: A Bottom-up Approach to Implementing A Proof Assistant' -t html --css styling.css -o html/index.html | ||
- name: Deploy HTML | ||
- name: Deploy GitHub pages | ||
uses: JamesIves/[email protected] | ||
if: ${{ success() && env.DOC_DEPLOY == 'true' }} | ||
with: | ||
|