feat: add script to autogenerate configuration page#958
Merged
rhamzeh merged 2 commits intofeat/add-auto-generated-config-pagefrom Feb 21, 2025
Merged
feat: add script to autogenerate configuration page#958rhamzeh merged 2 commits intofeat/add-auto-generated-config-pagefrom
rhamzeh merged 2 commits intofeat/add-auto-generated-config-pagefrom
Conversation
Contributor
|
9 tasks
ewanharris
reviewed
Feb 20, 2025
scripts/update-config-page.mjs
Outdated
| }); | ||
| } | ||
|
|
||
| jsonToMdx('https://raw.githubusercontent.com/openfga/openfga/refs/heads/main/.config-schema.json', 'docs/content/getting-started/setup-openfga/configuration.mdx'); No newline at end of file |
Member
There was a problem hiding this comment.
It might make it a little more complex to run, but if we fetched the latest release and fetched from that ref could we maybe integrate this into the build step? Something like
- Call
api.github.com/repos/openfga/openfga/releases/latestand retrievetag_name(currentlyv1.8.5) - Fetch
https://raw.githubusercontent.com/openfga/openfga/${tag_name}/.config-schema.json(currentlyhttps://raw.githubusercontent.com/openfga/openfga/v1.8.5/.config-schema.json)
c9ef801 to
0a23972
Compare
ewanharris
reviewed
Feb 20, 2025
scripts/update-config-page.mjs
Outdated
| `; | ||
| let mdxContent = mdxContentHeader + `## List of options | ||
|
|
||
| The following table lists the configuration options for the OpenFGA server, based on the [config-schema.json](https://github.com/openfga/openfga/blob/main/.config-schema.json). |
Member
There was a problem hiding this comment.
What do you think to having this point to the tag we generated from if we passed in the release value we get?
ewanharris
approved these changes
Feb 21, 2025
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.
Description
This is the script that generates the page in #938
It can be run using:
npm run update:config-pageReferences
Review Checklist
main