Skip to content

Add readthedocs documentation support #6299

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

Merged
merged 24 commits into from
Nov 11, 2020

Conversation

ggbecker
Copy link
Member

@ggbecker ggbecker commented Oct 26, 2020

Description:

  • Add files to support hosting documentation on: https://readthedocs.org
  • The developer_guide.adoc document has been broken into multiple files to enhance navigability
  • Since readthedocs.org doesn't support adoc, it was needed to convert some stuff around to markdown.

A preview of how the documentation will look like can be seen in:

https://ggbecker-content.readthedocs.io/en/readthedocs-support/

Rationale:

TODO List

- [ ] Port changes from: 1 (can be incorporated when it gets merged)

  • Port changes from: 2
  • Port changes from: 3
  • Port changes from: 4
  • Port changes from: 5
  • Write Technical Documentation about the integration itself - how to build the documentation and dependencies
  • Remove developer_guide.adoc references from project, mainly from CMakeLists.txt files
    - [ ] Migrate tests/README.md
    - [ ] Migrate docs/user_guide.adoc
    - [ ] Migrate example/README.md

Update1: Reduce the scope a bit so this can be merged and then other files can be migrated later.

@ggbecker ggbecker added the Documentation Update in project documentation. label Oct 26, 2020
@ggbecker ggbecker added this to the 0.1.53 milestone Oct 26, 2020
@pep8speaks
Copy link

pep8speaks commented Oct 26, 2020

Hello @ggbecker! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 17:1: E402 module level import not at top of file
Line 32:5: E128 continuation line under-indented for visual indent
Line 33:5: E128 continuation line under-indented for visual indent
Line 34:5: E128 continuation line under-indented for visual indent
Line 35:5: E128 continuation line under-indented for visual indent
Line 36:5: E128 continuation line under-indented for visual indent
Line 37:1: E124 closing bracket does not match visual indentation

Comment last updated at 2020-11-09 16:31:49 UTC

@openscap-ci
Copy link
Collaborator

openscap-ci commented Oct 26, 2020

Changes identified:
Others:
 Changes in Python files.

Show details

Others:
 Python file docs/conf.py is newly added.
 Python file tests/init.py is newly added.
 Python file utils/init.py is newly added.

Recommended tests to execute:
 (cd build && cmake ../ && ctest -j4)

@ggbecker ggbecker force-pushed the readthedocs-support branch from 8810718 to 68c751b Compare October 26, 2020 17:29
@jan-cerny jan-cerny changed the title Add readthedocs documentation support. Add readthedocs documentation support Oct 27, 2020
@jan-cerny
Copy link
Collaborator

It's amazing!

Suggestions:

  • link it from README
  • link it from the old page in case somebody has bookmarked the old page

Why are HTML tags used in the markdown docs?

@ggbecker
Copy link
Member Author

It's amazing!

Suggestions:

* link it from README

* link it from the old page in case somebody has bookmarked the old page

Why are HTML tags used in the markdown docs?

Thank you for the suggestions. I'll update accordingly.

HTML tags were automatically generated when converting from AsciiDoc to MarkDown. We will have to manually port some of those tables. But for now we can keep it like since it still renders a nice table.

@ggbecker
Copy link
Member Author

  • README had developer guide links updated to use new location in readthedocs
  • developer_guide.adoc has a deprecation note and the link to the new location.
  • I have added support to Jinja Macros Documentation

@ggbecker
Copy link
Member Author

The webhook to trigger builds on readthedocs is already in place, so pushes to master branch and new releases will automatically have the documentation generated

@ggbecker ggbecker force-pushed the readthedocs-support branch 2 times, most recently from 0b3d807 to bd55667 Compare October 29, 2020 15:51
@ggbecker
Copy link
Member Author

Python modules have been added to the documentation. You can preview the latest state here:

https://ggbecker-content.readthedocs.io/en/readthedocs-support/

@ggbecker ggbecker requested a review from jan-cerny October 29, 2020 15:58
@redhatrises
Copy link
Contributor

Description:

  • Add files to support hosting documentation on: https://readthedocs.org
  • The developer_guide.adoc document has been broken into multiple files to enhance navigability
  • Since readthedocs.org doesn't support adoc, it was needed to convert some stuff around to markdown.

A preview of how the documentation will look like can be seen in:

https://ggbecker-content.readthedocs.io/en/readthedocs-support/

Rationale:

Is the developer guide readable without an internet connect in the repo itself? If not, that needs to be taken care of. Never assume access to an internet resource to read documentation.

@ggbecker
Copy link
Member Author

Description:

  • Add files to support hosting documentation on: https://readthedocs.org
  • The developer_guide.adoc document has been broken into multiple files to enhance navigability
  • Since readthedocs.org doesn't support adoc, it was needed to convert some stuff around to markdown.

A preview of how the documentation will look like can be seen in:
https://ggbecker-content.readthedocs.io/en/readthedocs-support/

Rationale:

Is the developer guide readable without an internet connect in the repo itself? If not, that needs to be taken care of. Never assume access to an internet resource to read documentation.

The documentation still lives in the repo. They were just split and reside on a different directory: https://github.com/ggbecker/content/tree/readthedocs-support/docs/manual/developer

The documentation could be also built locally using sphinx tools and we can add as a target in the make command so users can have the same HTML files that readthedocs generate.

If we think about it, users that browse files locally, would also need to have a AsciiDoc processor to render the text, so we would be just changing the prerequisite.

@JAORMX
Copy link
Contributor

JAORMX commented Oct 30, 2020

Recently added docs for the ocp4 e2e tests #6319 any chance that could be included?

@ggbecker
Copy link
Member Author

Recently added docs for the ocp4 e2e tests #6319 any chance that could be included?

Definitely. Thanks for the reminder.

@ggbecker
Copy link
Member Author

Copy link
Collaborator

@jan-cerny jan-cerny left a comment

Choose a reason for hiding this comment

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

It's amazing.

I appreciate the idea of adding the Python modules documentation.

In future I suggest reshuffling the sections and chapters a bit, because for example templates are hidden well.

@matejak matejak mentioned this pull request Nov 3, 2020
@ggbecker ggbecker force-pushed the readthedocs-support branch 3 times, most recently from f548c48 to 7fc92af Compare November 6, 2020 16:03
@openshift-ci-robot openshift-ci-robot added the needs-rebase Used by openshift-ci bot. label Nov 9, 2020
@ggbecker ggbecker force-pushed the readthedocs-support branch from 7fc92af to 356cb49 Compare November 9, 2020 08:53
@openshift-ci-robot openshift-ci-robot removed the needs-rebase Used by openshift-ci bot. label Nov 9, 2020
@JAORMX
Copy link
Contributor

JAORMX commented Nov 9, 2020

/test e2e-aws-rhcos4-e8

test flake

@yuumasato yuumasato modified the milestones: 0.1.53, 0.1.54 Nov 11, 2020
@matejak matejak self-assigned this Nov 11, 2020
@matejak
Copy link
Member

matejak commented Nov 11, 2020

Great, I see no objections, and the existing documentation has just been converted to Markdown, which means that it's prefectly usable offline.
So let's merge this before conflicts develop. Looking forward to follow-ups!

@matejak matejak merged commit 9d011f5 into ComplianceAsCode:master Nov 11, 2020
@yuumasato yuumasato added the Highlight This PR/Issue should make it to the featured changelog. label Feb 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Documentation Update in project documentation. Highlight This PR/Issue should make it to the featured changelog.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants