-
Notifications
You must be signed in to change notification settings - Fork 323
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
Auto Generate Docs #802
Auto Generate Docs #802
Conversation
762d193
to
3ad9110
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Awesome change!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
@armsnyder I fixed a conflict. Let's merge if everything is green. |
- New make target "reviewable" which is the default - New make target "generate" for generaring provider docs - Remove tool dependencies from go.mod and go.sum - Move tool dependencies into /tools directory as a separate Go module to be maintained by dependabot - Consolidate GitHub Actions for PRs to one file test.yml - Cache go modules and tools in CI workflows - Add linters and formatters for examples
- Move attribute documentation to resource schemas - Move examples to /examples
Handcrafted changes to schema descriptions and examples
This functionality has been released in 3.9.0 of the Terraform GitLab Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. For further feature requests or bug reports with this functionality, please create a new GitHub issue. Thank you! |
Description
Overview
Fixes #543
This PR adds automatic generation for the entire /docs directory, based on the
Description
schema fields in-code and examples in /examples, as recommended in the Terraform docs guide. It also validates that documentation was generated correctly during the CI workflow.I am very excited to have this feature, because it will lift a huge burden on PR reviewers to check accuracy of documentation.
Since this PR includes the newly generated documentation, it also fixes all of our existing documentation inaccuracies.
Notes
test.yaml
workflow file.tools.go
and into the a /tools directory, which is its own module, in the style of the cloudflare and newrelic providers. The upshot is thatmake
is slightly faster, and we don't pollute ourgo.mod
andgo.sum
with dev dependencies, and dependabot is still able to handle tool version updates.make
targetmake reviewable
as a one-stop-shop for linting and now generating code, inspired by crossplane.PR Checklist
//lintignore
comments that came from copied code. Linter rules are meant to be enforced on new code.