-
Notifications
You must be signed in to change notification settings - Fork 195
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
Generate Documentation with Alectryon #1455
Conversation
d74186f
to
72a6455
Compare
This is by far the slowest build job at 32 minutes, but I think that's okay. Documentation now at https://github.com/HoTT/HoTT/suites/2489508125/artifacts/53701473 |
@JasonGross Perhaps it is worth having a gitlab mirror so we can at least have better artefacts? |
Having a GitLab mirror sounds good, though I don't know how to set it up. Do you have experience setting up GitLab mirrors/CI? |
I have no idea how to but I can look into it. |
I've just rebased this. Should we merge it as-is, and we can improve it / move it to GitLab later? |
I had a look at the documentation files, but they are not formatted (I guess no css?) Perhaps I am not looking at them correctly? Also is this still using proviola? I am unsure if the CI is taking long to use Alectryon or because its still messing around with proviola? |
There should be css files included in the relevant directory, if not I'll have to debug. This job is completely independent from the proviola one, and should be running in parallel. It seems that it takes about 10 minutes to build the repo and then about 20 minutes after that to build the alectryon doc. Unfortunately I'm not aware of any way to do them simultaneously. @cpitclaudel do you think we can get a mode where alectryon replaces coqc and dumps both the html and the vo for each file? |
@JasonGross Actually I think it's fine. I was peaking in the zip before which is why the css wasn't working. After extracting it it works fine. |
But looking at the documentation, this is really nice! If we can make it more accessible from a PR it will be very useful! |
That's my hope, too! We may even be able to set up @coqbot or similar to stick a link to the generated documentation in the checks/status. |
How do you build the new documentation locally? I did There were various warnings like:
|
(I also did the build fresh from the start, with autogen, make clean, etc.) |
Documentation is now live on the wiki:
|
@jdchristensen Assuming you have |
Wonderful work, Jason! :)
That would be nice! But I don't know to which extend Coq knows how to do this (we have this come up from time to time in PG too, where we're asked whether we could just dump a .vo using a command. Do you know if that's something the STM can do? If yes, it would just be a matter of calling the right command. |
Indeed, we should probably switch to whatever rst uses for verbatim blocks so they get rendered nicely, or otherwise figure out how to fix the warnings. |
That's a Coqdoc warning, right? I'm surprised that it pops up — maybe Alectryon isn't feeding the coqdoc comments to coqdoc the right way? |
Ah, this is because we're reusing the coqdoc files for the toc and index. Once Alectryon can generate a toc and index for us, we'll stop using coqdoc. |
On top of #1453
Closes #1435
Currently uses my fork of Alectryon, until cpitclaudel/alectryon#25 gets merged.
I've set this up as a Docker action (which requires running the bulk of the action in a single step, unfortunately), so that I have access to
opam
with a pre-installed Coq, so that I can installcoq-serapi
without having to build it manually on the CI.This action will upload an artifact containing the HTML on PRs, so it's possible (if a tad bit annoying) to browse the generated documentation on PRs. (Unless there's a way to browse the inside of .zip files from inside a browser without downloading them locally?) Additionally, it'll push the docs to gh-pages on master (hopefully I didn't screw this up).
Here's some pictures:
It would be nice if Alectryon had
--toc
/--index
options (cc @cpitclaudel), because right now I'm just copying over the jank TOC and index generated by coqdoc: