Skip to content

Support renamed gen_reference_docs target in Mintlify docs check - #2910

Open
kapunahelewong wants to merge 1 commit into
bazelbuild:masterfrom
kapunahelewong:rename-gen-reference-docs
Open

kapunahelewong wants to merge 1 commit into
bazelbuild:masterfrom
kapunahelewong:rename-gen-reference-docs

Conversation

@kapunahelewong

@kapunahelewong kapunahelewong commented Oct 1, 2026 •

Copy link
Copy Markdown

Related to bazelbuild/bazel#31211.

mintlify/check_docs.sh hardcodes //src/main/java/com/google/devtools/build/lib:gen_mdx_reference_docs and mdx-reference-docs.zip. bazelbuild/bazel#31268 renames the target to gen_reference_docs, so after it merges, the docs check on Bazel PRs would fail because it can't find the target.

This PR:

  • builds gen_reference_docs if the checked-out Bazel defines it, and otherwise falls back to gen_mdx_reference_docs, so older commits and release branches still work.
  • gets the archive name from bazel cquery --output=files instead of hardcoding it, so it also handles the draft Rename mdx-reference-docs.zip to reference-docs.zip bazel#31269 (mdx-reference-docs.zip → reference-docs.zip). The uploaded artifact path stays under bazel-bin/ as before.

Merge order: this should be merged, and the gcr.io/bazel-public/mintlify image rebuilt, before bazelbuild/bazel#31268 merges.

Testing

I ran the new selection logic against three Bazel checkouts:

Bazel checkout Target built Archive
master (before rename) gen_mdx_reference_docs mdx-reference-docs.zip
bazelbuild/bazel#31268 gen_reference_docs mdx-reference-docs.zip
bazelbuild/bazel#31269 gen_reference_docs reference-docs.zip

I haven't run it inside the Docker image or on Buildkite.

Related PRs

Issue: bazelbuild/bazel#31211

bazelbuild/bazel bazel-contrib/bazel-docs bazelbuild/continuous-integration
Rename target gen_mdx_reference_docs → gen_reference_docs bazelbuild/bazel#31268 bazel-contrib/bazel-docs#777 #2910
Rename output mdx-reference-docs.zip → reference-docs.zip (draft) bazelbuild/bazel#31269 bazel-contrib/bazel-docs#778 (covered by #2910)

The bazel-docs and continuous-integration PRs accept both the old and new names. The bazel-docs PRs can merge in any order.

🤖 Generated with Claude Code

bazelbuild/bazel#31268 renames gen_mdx_reference_docs to
gen_reference_docs, and the draft bazelbuild/bazel#31269 renames its
output from mdx-reference-docs.zip to reference-docs.zip. Build
whichever target the checked-out Bazel defines and ask Bazel for the
output name, so the check works before and after both renames.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant