Repository navigation
feat: compose saved editions into one versioned site - #381
Draft
brendanclement wants to merge 5 commits into
Draft
brendanclement wants to merge 5 commits into
brendanclement wants to merge 5 commits into
Conversation
`scripts/compose.py`, run with `make compose`, publishes every saved edition as saved under `/<product>/v<major>-<minor>-<patch>/`, with Mintlify's own product and version selectors, and adds an "About this version" page made from its record. Nothing is rebuilt, and an edition that does not match its record is not composed. `compose.yaml` orders the products, Enterprise first, and names each product's preferred edition, which only that file changes. Links, images and imports are pointed into their own edition; a link that would leave it stops composition. Code is left as written, and a file an example downloads stays at its address, the same for every edition. Each edition keeps its redirects and drafts. Unversioned paths redirect, temporarily, to the same page of the default edition, and paths it lacks are listed rather than redirected.
README.md says how to compose, check and preview the site, how links, downloads, site-wide files, redirects and drafts are handled, and where the preferred editions are set. VERSIONING.md marks the step in place, though nothing publishes its site yet.
This branch has not been deployed
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.
Problem
We can save documentation for a release, but those editions still need to become one website that readers can browse by product and version.
Solution
Add
make composeto build that site using Mintlify's product and version selectors. Each edition keeps its pages, badges and drafts, and gets an About this version page. Links and assets stay within the selected edition; old unversioned links go to the preferred Enterprise edition.compose.yamlchooses the preferred editions. Adding a release does not change that choice automatically. The composer checks saved-edition checksums and rejects unsafe links, redirect loops and unsupported link syntax.This is PR 2 of 4, stacked on #379. It adds no real editions or publication workflow. PR 3 will connect the composed site to staging and approved production promotion; PR 4 will prepare editions from qualified releases.
Validation
Mintlify switches to the preferred landing page when changing products. Opening its assistant sidebar can still truncate the product label at narrower widths. The preview uses JSON for its test download because the site's current plan did not serve TXT.
The Assemble workflow currently runs only for PRs targeting
main, so this stacked draft does not get that hosted check yet.