Skip to content

Commit

Permalink
fix(stardoc): upgrade and stop skipping under bzlmod
Browse files Browse the repository at this point in the history
Newest stardoc has fixed it, and since bzlmod will select the lowest
version in the dependencies, our bump here will take effect for users
as well.
  • Loading branch information
alexeagle committed May 17, 2023
1 parent b0f4558 commit 9b14866
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
10 changes: 7 additions & 3 deletions MODULE.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ module(
version = "0.0.0",
)

# Lower-bound versions of our dependencies
bazel_dep(name = "bazel_skylib", version = "1.4.1")
bazel_dep(name = "bazel_skylib_gazelle_plugin", version = "1.4.1", dev_dependency = True)
bazel_dep(name = "platforms", version = "0.0.4")
bazel_dep(name = "stardoc", repo_name = "io_bazel_stardoc", version = "0.5.0")
# 0.5.4 is the first version with bzlmod support
bazel_dep(name = "stardoc", repo_name = "io_bazel_stardoc", version = "0.5.4")

ext = use_extension("@aspect_bazel_lib//lib:extensions.bzl", "ext")

use_repo(ext, "copy_directory_toolchains", "copy_to_directory_toolchains", "jq_toolchains", "yq_toolchains", "coreutils_toolchains", "expand_template_toolchains")


register_toolchains(
"@copy_directory_toolchains//:all",
"@copy_to_directory_toolchains//:all",
Expand All @@ -24,3 +24,7 @@ register_toolchains(
"@coreutils_toolchains//:all",
"@expand_template_toolchains//:all"
)

# Development-only dependencies

bazel_dep(name = "bazel_skylib_gazelle_plugin", version = "1.4.1", dev_dependency = True)
3 changes: 0 additions & 3 deletions lib/private/docs.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,6 @@ def stardoc_with_diff_test(
"""

target_compatible_with = kwargs.pop("target_compatible_with", select({
# stardoc doesn't work under bzlmod:
# https://github.com/bazelbuild/bazel/issues/14140
"@aspect_bazel_lib//lib:bzlmod": ["@platforms//:incompatible"],
# stardoc produces different line endings on Windows
# which makes the diff_test fail
"@platforms//os:windows": ["@platforms//:incompatible"],
Expand Down

0 comments on commit 9b14866

Please sign in to comment.