Update docs/api.md
and automatically update it
#612
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Each time we change the CRDs we do update part of our documentation in
./docs/api/index.html
, but this document is hardly readable for anyone and does not render well on the GitHub UI either. The better way of showing this documentation is by just changing the file extension to Markdown and GitHub will know how to render it. We do have the Markdown version of./docs/api/index.html
, which is located in./docs/api.md
. However, we have not updated this file in several years despite the many changes to vitess-operator.This is an issue as
./docs/api.md
is supposed to be the only very-up-to-date documentation we have for vitess-operator.This PR fixes this issue by adding a phase to
make generate
that will copy the newly generated./docs/api/index.html
into./docs/api.md
and remove the first two line of the file (which contain HTML headers that do not render well in Markdown).Adding this as part of
make generate
will ensure that the documentation will always be consistent as we have a CI checks that makes suremake generate
has been run on any new commit.