docs: add doc generation script, metadata schema, and cleanup #1232
Merged
Conversation
✅ Deploy Preview for krm-function-catalog canceled.
|
Contributor
There was a problem hiding this comment.
Pull request overview
This PR modernizes the function documentation workflow by replacing the legacy Go-based doc/tag updater with a Hugo doc generation + metadata schema validation approach, and cleans up metadata to align with the new schema.
Changes:
- Add
scripts/generate_docs/generate_docs.shto generate Hugo pages fromREADME.md+metadata.yamland addvalidate_metadata.sh+ CI job to validate metadata. - Introduce
functions/go/metadata-schema.jsonand remove the legacyupdate_function_docsandpatch_readertooling. - Normalize function metadata by removing the
emailsfield and removing a duplicate metadata file inapply-setters.
Reviewed changes
Copilot reviewed 33 out of 36 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| scripts/update_function_docs/main.go | Removes legacy Go-based doc update CLI. |
| scripts/update_function_docs/git.go | Removes legacy git helper for doc updater. |
| scripts/update_function_docs/function_release.go | Removes legacy tag/URL rewrite logic for docs/examples. |
| scripts/update_function_docs/go.mod | Removes legacy module definition for doc updater. |
| scripts/update_function_docs/go.sum | Removes legacy dependency lockfile for doc updater. |
| scripts/patch_reader/main.go | Removes legacy patch version helper CLI. |
| scripts/patch_reader/pkg/latestpatch/latestpatch.go | Removes legacy git-tag scanning logic for latest patch discovery. |
| scripts/patch_reader/go.mod | Removes legacy module definition for patch reader. |
| scripts/patch_reader/go.sum | Removes legacy dependency lockfile for patch reader. |
| scripts/generate_docs/generate_docs.sh | Adds new Hugo doc generation/sync script. |
| scripts/generate_docs/validate_metadata.sh | Adds schema validation script for metadata.yaml. |
| functions/go/metadata-schema.json | Adds JSON Schema for Go function metadata. |
| functions/go/apply-setters/metadata.yaml | Removes emails field from metadata. |
| functions/go/apply-replacements/metadata.yaml | Removes emails field from metadata. |
| functions/go/create-setters/metadata.yaml | Removes emails field from metadata. |
| functions/go/ensure-name-substring/metadata.yaml | Removes emails field from metadata. |
| functions/go/gatekeeper/metadata.yaml | Removes emails field from metadata. |
| functions/go/generate-kpt-pkg-docs/metadata.yaml | Removes emails field from metadata. |
| functions/go/list-setters/metadata.yaml | Removes emails field from metadata. |
| functions/go/remove-local-config-resources/metadata.yaml | Removes emails field from metadata. |
| functions/go/render-helm-chart/metadata.yaml | Removes emails field from metadata. |
| functions/go/search-replace/metadata.yaml | Removes emails field from metadata. |
| functions/go/set-annotations/metadata.yaml | Removes emails field from metadata. |
| functions/go/set-enforcement-action/metadata.yaml | Removes emails field from metadata. |
| functions/go/set-image/metadata.yaml | Removes emails field from metadata. |
| functions/go/set-labels/metadata.yaml | Removes emails field from metadata. |
| functions/go/set-namespace/metadata.yaml | Removes emails field from metadata. |
| functions/go/sleep/metadata.yaml | Removes emails field from metadata. |
| functions/go/starlark/metadata.yaml | Removes emails field from metadata. |
| functions/go/upsert-resource/metadata.yaml | Removes emails field from metadata. |
| functions/go/apply-setters/krm-fn-metadata.yaml | Removes duplicate legacy metadata file. |
| RELEASING.md | Updates release/docs workflow to use the new generation script. |
| README.md | Updates documentation pointers and fixes a wording typo. |
| Makefile | Replaces update-function-docs with validate-metadata target. |
| .gitignore | Stops ignoring removed patch_reader binary; adds .local/. |
| .github/workflows/ci.yaml | Adds CI job to validate metadata against the schema. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
CsatariGergely
approved these changes
Apr 16, 2026
…scripts Signed-off-by: Fiachra Corcoran <fiachra.corcoran@est.tech>
Signed-off-by: Fiachra Corcoran <fiachra.corcoran@est.tech>
4538572 to
209b13c
Compare
CsatariGergely
approved these changes
Apr 16, 2026
liamfallon
approved these changes
Apr 16, 2026
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Add doc generation script and metadata schema
README.md and metadata.yaml