Add support for Bzlmod (#141)

Input .bzl files are turned into runfiles of a custom Stardoc binary, which allows reusing the Java runfiles library to load the files while taking repository mappings into account.
diff --git a/MODULE.bazel b/MODULE.bazel
new file mode 100644
index 0000000..6617467
--- /dev/null
+++ b/MODULE.bazel
@@ -0,0 +1,9 @@
+module(
+    name = "stardoc",
+    version = "0.5.3",
+    compatibility_level = 1,
+)
+
+bazel_dep(name = "bazel_skylib", version = "1.2.1")
+bazel_dep(name = "rules_java", version = "5.3.5")
+bazel_dep(name = "rules_license", version = "0.0.3")
diff --git a/WORKSPACE b/WORKSPACE
index 37f258a..fc5ffad 100644
--- a/WORKSPACE
+++ b/WORKSPACE
@@ -14,10 +14,8 @@
 # Needed for generating the Stardoc release binary.
 git_repository(
     name = "io_bazel",
-    commit = "901c75e459d737220cb8e29649c1b6ba24e2221d",  # Sep 27, 2022
-    patches = ["@//:bazel.patch"],  # TODO: Remove after next bazel update
+    commit = "c6a8c0827061697fa8fa9dd21310b276d9887e8c",  # 2023-04-27
     remote = "https://github.com/bazelbuild/bazel.git",
-    shallow_since = "1664304093 -0700",
 )
 
 # The following binds are needed for building protobuf java libraries.
@@ -36,6 +34,68 @@
     actual = "@io_bazel//third_party:error_prone_annotations",
 )
 
+RULES_JVM_EXTERNAL_TAG = "4.5"
+
+RULES_JVM_EXTERNAL_SHA = "b17d7388feb9bfa7f2fa09031b32707df529f26c91ab9e5d909eb1676badd9a6"
+
+http_archive(
+    name = "rules_jvm_external",
+    sha256 = RULES_JVM_EXTERNAL_SHA,
+    strip_prefix = "rules_jvm_external-%s" % RULES_JVM_EXTERNAL_TAG,
+    url = "https://github.com/bazelbuild/rules_jvm_external/archive/refs/tags/%s.zip" % RULES_JVM_EXTERNAL_TAG,
+)
+
+load("@rules_jvm_external//:repositories.bzl", "rules_jvm_external_deps")
+
+rules_jvm_external_deps()
+
+load("@rules_jvm_external//:setup.bzl", "rules_jvm_external_setup")
+
+rules_jvm_external_setup()
+
+load("@rules_jvm_external//:defs.bzl", "maven_install")
+
+maven_install(
+    artifacts = [
+        "com.github.ben-manes.caffeine:caffeine:3.0.5",
+        "com.github.stephenc.jcip:jcip-annotations:1.0-1",
+        "com.google.auto.service:auto-service-annotations:1.0.1",
+        "com.google.auto.service:auto-service:1.0",
+        "com.google.auto.value:auto-value-annotations:1.9",
+        "com.google.auto.value:auto-value:1.8.2",
+        "com.google.auto:auto-common:1.2.1",
+        "com.google.code.findbugs:jsr305:3.0.2",
+        "com.google.code.gson:gson:2.9.0",
+        "com.google.errorprone:error_prone_annotations:2.18.0",
+        "com.google.errorprone:error_prone_type_annotations:2.18.0",
+        "com.google.flogger:flogger-system-backend:0.5.1",
+        "com.google.flogger:flogger:0.5.1",
+        "com.google.flogger:google-extensions:0.5.1",
+        "com.google.guava:failureaccess:1.0.1",
+        "com.google.guava:guava:31.1-jre",
+        "com.google.j2objc:j2objc-annotations:1.3",
+        "com.ryanharter.auto.value:auto-value-gson-extension:1.3.1",
+        "com.ryanharter.auto.value:auto-value-gson-runtime:1.3.1",
+        "com.ryanharter.auto.value:auto-value-gson-factory:1.3.1",
+        "com.squareup:javapoet:1.12.0",
+        "commons-collections:commons-collections:3.2.2",
+        "commons-lang:commons-lang:2.6",
+        "org.apache.tomcat:tomcat-annotations-api:8.0.5",
+        "org.apache.velocity:velocity:1.7",
+        "org.checkerframework:checker-qual:3.19.0",
+    ],
+    fail_if_repin_required = True,
+    maven_install_json = "//:maven_install.json",
+    repositories = [
+        "https://repo1.maven.org/maven2",
+    ],
+    strict_visibility = True,
+)
+
+load("@maven//:defs.bzl", "pinned_maven_install")
+
+pinned_maven_install()
+
 # Needed only because of java_tools.
 http_archive(
     name = "rules_cc",
@@ -48,11 +108,11 @@
 )
 
 # Needed as a transitive dependency of @io_bazel
-git_repository(
+http_archive(
     name = "rules_python",
-    commit = "4b84ad270387a7c439ebdccfd530e2339601ef27",
-    remote = "https://github.com/bazelbuild/rules_python.git",
-    shallow_since = "1564776078 -0400",
+    sha256 = "a644da969b6824cc87f8fe7b18101a8a6c57da5db39caa6566ec6109f37d2141",
+    strip_prefix = "rules_python-0.20.0",
+    urls = ["https://github.com/bazelbuild/rules_python/releases/download/0.20.0/rules_python-0.20.0.tar.gz"],
 )
 
 # Needed for //distro:__pkg__ and as a transitive dependency of @io_bazel
@@ -72,10 +132,10 @@
 # Needed as a transitive dependency of @io_bazel
 http_archive(
     name = "rules_proto",
-    sha256 = "9850fcf6ad40fa348e6f13b2cfef4bb4639762f804794f2bf61d988f4ba0dae9",
-    strip_prefix = "rules_proto-4.0.0-3.19.2-2",
+    sha256 = "dc3fb206a2cb3441b485eb1e423165b231235a1ea9b031b4433cf7bc1fa460dd",
+    strip_prefix = "rules_proto-5.3.0-21.7",
     urls = [
-        "https://github.com/bazelbuild/rules_proto/archive/refs/tags/4.0.0-3.19.2-2.tar.gz",
+        "https://github.com/bazelbuild/rules_proto/archive/refs/tags/5.3.0-21.7.tar.gz",
     ],
 )
 
diff --git a/bazel.patch b/bazel.patch
deleted file mode 100644
index bba62e9..0000000
--- a/bazel.patch
+++ /dev/null
@@ -1,14 +0,0 @@
---- src/main/native/BUILD
-+++ src/main/native/BUILD
-@@ -71,7 +71,10 @@ cc_binary(
-     ],
-     includes = ["."],  # For jni headers.
-     linkopts = select({
--        "//src/conditions:darwin": ["-framework CoreServices"],
-+        "//src/conditions:darwin": [
-+            "-Wl,-framework,CoreServices",
-+            "-Wl,-framework,IOKit",
-+        ],
-         "//conditions:default": [],
-     }),
-     linkshared = 1,
diff --git a/docs/stardoc_rule.md b/docs/stardoc_rule.md
index 532855a..2532abe 100644
--- a/docs/stardoc_rule.md
+++ b/docs/stardoc_rule.md
@@ -7,34 +7,31 @@
 ## stardoc
 
 <pre>
-stardoc(<a href="#stardoc-name">name</a>, <a href="#stardoc-aspect_template">aspect_template</a>, <a href="#stardoc-deps">deps</a>, <a href="#stardoc-format">format</a>, <a href="#stardoc-func_template">func_template</a>, <a href="#stardoc-header_template">header_template</a>, <a href="#stardoc-input">input</a>, <a href="#stardoc-out">out</a>,
-        <a href="#stardoc-provider_template">provider_template</a>, <a href="#stardoc-renderer">renderer</a>, <a href="#stardoc-rule_template">rule_template</a>, <a href="#stardoc-semantic_flags">semantic_flags</a>, <a href="#stardoc-stardoc">stardoc</a>, <a href="#stardoc-symbol_names">symbol_names</a>)
+stardoc(<a href="#stardoc-name">name</a>, <a href="#stardoc-input">input</a>, <a href="#stardoc-out">out</a>, <a href="#stardoc-deps">deps</a>, <a href="#stardoc-format">format</a>, <a href="#stardoc-symbol_names">symbol_names</a>, <a href="#stardoc-semantic_flags">semantic_flags</a>, <a href="#stardoc-stardoc">stardoc</a>, <a href="#stardoc-renderer">renderer</a>,
+        <a href="#stardoc-aspect_template">aspect_template</a>, <a href="#stardoc-func_template">func_template</a>, <a href="#stardoc-header_template">header_template</a>, <a href="#stardoc-provider_template">provider_template</a>, <a href="#stardoc-rule_template">rule_template</a>, <a href="#stardoc-kwargs">kwargs</a>)
 </pre>
 
+Generates documentation for exported starlark rule definitions in a target starlark file.
 
-Generates documentation for exported skylark rule definitions in a target starlark file.
-
-This rule is an experimental replacement for the existing skylark_doc rule.
+**PARAMETERS**
 
 
-**ATTRIBUTES**
-
-
-| Name  | Description | Type | Mandatory | Default |
-| :------------- | :------------- | :------------- | :------------- | :------------- |
-| <a id="stardoc-name"></a>name |  A unique name for this target.   | <a href="https://bazel.build/concepts/labels#target-names">Name</a> | required |  |
-| <a id="stardoc-aspect_template"></a>aspect_template |  The input file template for generating documentation of aspects.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>//stardoc:templates/markdown_tables/aspect.vm</code> |
-| <a id="stardoc-deps"></a>deps |  A list of bzl_library dependencies which the input depends on.   | <a href="https://bazel.build/concepts/labels">List of labels</a> | optional | <code>[]</code> |
-| <a id="stardoc-format"></a>format |  The format of the output file. Valid values: 'markdown' or 'proto'.   | String | optional | <code>"markdown"</code> |
-| <a id="stardoc-func_template"></a>func_template |  The input file template for generating documentation of functions.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>//stardoc:templates/markdown_tables/func.vm</code> |
-| <a id="stardoc-header_template"></a>header_template |  The input file template for the header of the output documentation.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>//stardoc:templates/markdown_tables/header.vm</code> |
-| <a id="stardoc-input"></a>input |  The starlark file to generate documentation for.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>None</code> |
-| <a id="stardoc-out"></a>out |  The (markdown) file to which documentation will be output.   | <a href="https://bazel.build/concepts/labels">Label</a> | required |  |
-| <a id="stardoc-provider_template"></a>provider_template |  The input file template for generating documentation of providers.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>//stardoc:templates/markdown_tables/provider.vm</code> |
-| <a id="stardoc-renderer"></a>renderer |  The location of the renderer tool.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>//stardoc:renderer</code> |
-| <a id="stardoc-rule_template"></a>rule_template |  The input file template for generating documentation of rules.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>//stardoc:templates/markdown_tables/rule.vm</code> |
-| <a id="stardoc-semantic_flags"></a>semantic_flags |  A list of canonical flags to affect Starlark semantics for the Starlark interpretter during documentation generation. This should only be used to maintain compatibility with non-default semantic flags required to use the given Starlark symbols.<br><br>For example, if <code>//foo:bar.bzl</code> does not build except when a user would specify <code>--incompatible_foo_semantic=false</code>, then this attribute should contain "--incompatible_foo_semantic=false".   | List of strings | optional | <code>[]</code> |
-| <a id="stardoc-stardoc"></a>stardoc |  The location of the stardoc tool.   | <a href="https://bazel.build/concepts/labels">Label</a> | optional | <code>//stardoc:stardoc</code> |
-| <a id="stardoc-symbol_names"></a>symbol_names |  A list of symbol names to generate documentation for. These should correspond to the names of rule definitions in the input file. If this list is empty, then documentation for all exported rule definitions will be generated.   | List of strings | optional | <code>[]</code> |
+| Name  | Description | Default Value |
+| :------------- | :------------- | :------------- |
+| <a id="stardoc-name"></a>name |  The name of the stardoc target.   |  none |
+| <a id="stardoc-input"></a>input |  The starlark file to generate documentation for (mandatory).   |  none |
+| <a id="stardoc-out"></a>out |  The file to which documentation will be output (mandatory).   |  none |
+| <a id="stardoc-deps"></a>deps |  A list of bzl_library dependencies which the input depends on.   |  <code>[]</code> |
+| <a id="stardoc-format"></a>format |  The format of the output file. Valid values: 'markdown' or 'proto'.   |  <code>"markdown"</code> |
+| <a id="stardoc-symbol_names"></a>symbol_names |  A list of symbol names to generate documentation for. These should correspond to the names of rule definitions in the input file. If this list is empty, then documentation for all exported rule definitions will be generated.   |  <code>[]</code> |
+| <a id="stardoc-semantic_flags"></a>semantic_flags |  A list of canonical flags to affect Starlark semantics for the Starlark interpreter during documentation generation. This should only be used to maintain compatibility with non-default semantic flags required to use the given Starlark symbols.<br><br>For example, if <code>//foo:bar.bzl</code> does not build except when a user would specify <code>--incompatible_foo_semantic=false</code>, then this attribute should contain "--incompatible_foo_semantic=false".   |  <code>[]</code> |
+| <a id="stardoc-stardoc"></a>stardoc |  The location of the stardoc tool.   |  <code>Label("//stardoc:prebuilt_stardoc_binary")</code> |
+| <a id="stardoc-renderer"></a>renderer |  The location of the renderer tool.   |  <code>Label("//stardoc:renderer")</code> |
+| <a id="stardoc-aspect_template"></a>aspect_template |  The input file template for generating documentation of aspects   |  <code>Label("//stardoc:templates/markdown_tables/aspect.vm")</code> |
+| <a id="stardoc-func_template"></a>func_template |  The input file template for generating documentation of functions.   |  <code>Label("//stardoc:templates/markdown_tables/func.vm")</code> |
+| <a id="stardoc-header_template"></a>header_template |  The input file template for the header of the output documentation.   |  <code>Label("//stardoc:templates/markdown_tables/header.vm")</code> |
+| <a id="stardoc-provider_template"></a>provider_template |  The input file template for generating documentation of providers.   |  <code>Label("//stardoc:templates/markdown_tables/provider.vm")</code> |
+| <a id="stardoc-rule_template"></a>rule_template |  The input file template for generating documentation of rules.   |  <code>Label("//stardoc:templates/markdown_tables/rule.vm")</code> |
+| <a id="stardoc-kwargs"></a>kwargs |  Further arguments to pass to stardoc.   |  none |
 
 
diff --git a/maven_install.json b/maven_install.json
new file mode 100644
index 0000000..0ff1d50
--- /dev/null
+++ b/maven_install.json
@@ -0,0 +1,677 @@
+{
+    "dependency_tree": {
+        "__AUTOGENERATED_FILE_DO_NOT_MODIFY_THIS_FILE_MANUALLY": "THERE_IS_NO_DATA_ONLY_ZUUL",
+        "__INPUT_ARTIFACTS_HASH": 1429940565,
+        "__RESOLVED_ARTIFACTS_HASH": 1065334191,
+        "conflict_resolution": {},
+        "dependencies": [
+            {
+                "coord": "com.github.ben-manes.caffeine:caffeine:3.0.5",
+                "dependencies": [
+                    "com.google.errorprone:error_prone_annotations:2.18.0",
+                    "org.checkerframework:checker-qual:3.19.0"
+                ],
+                "directDependencies": [
+                    "com.google.errorprone:error_prone_annotations:2.18.0",
+                    "org.checkerframework:checker-qual:3.19.0"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/github/ben-manes/caffeine/caffeine/3.0.5/caffeine-3.0.5.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/github/ben-manes/caffeine/caffeine/3.0.5/caffeine-3.0.5.jar"
+                ],
+                "packages": [
+                    "com.github.benmanes.caffeine.cache",
+                    "com.github.benmanes.caffeine.cache.stats"
+                ],
+                "sha256": "8a9b54d3506a3b92ee46b217bcee79196b21ca6d52dc2967c686a205fb2f9c15",
+                "url": "https://repo1.maven.org/maven2/com/github/ben-manes/caffeine/caffeine/3.0.5/caffeine-3.0.5.jar"
+            },
+            {
+                "coord": "com.github.stephenc.jcip:jcip-annotations:1.0-1",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/github/stephenc/jcip/jcip-annotations/1.0-1/jcip-annotations-1.0-1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/github/stephenc/jcip/jcip-annotations/1.0-1/jcip-annotations-1.0-1.jar"
+                ],
+                "packages": [
+                    "net.jcip.annotations"
+                ],
+                "sha256": "4fccff8382aafc589962c4edb262f6aa595e34f1e11e61057d1c6a96e8fc7323",
+                "url": "https://repo1.maven.org/maven2/com/github/stephenc/jcip/jcip-annotations/1.0-1/jcip-annotations-1.0-1.jar"
+            },
+            {
+                "coord": "com.google.auto.service:auto-service-annotations:1.0.1",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/auto/service/auto-service-annotations/1.0.1/auto-service-annotations-1.0.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/auto/service/auto-service-annotations/1.0.1/auto-service-annotations-1.0.1.jar"
+                ],
+                "packages": [
+                    "com.google.auto.service"
+                ],
+                "sha256": "c7bec54b7b5588b5967e870341091c5691181d954cf2039f1bf0a6eeb837473b",
+                "url": "https://repo1.maven.org/maven2/com/google/auto/service/auto-service-annotations/1.0.1/auto-service-annotations-1.0.1.jar"
+            },
+            {
+                "coord": "com.google.auto.service:auto-service:1.0",
+                "dependencies": [
+                    "com.google.auto.service:auto-service-annotations:1.0.1",
+                    "com.google.auto:auto-common:1.2.1",
+                    "com.google.guava:guava:31.1-jre"
+                ],
+                "directDependencies": [
+                    "com.google.auto.service:auto-service-annotations:1.0.1",
+                    "com.google.auto:auto-common:1.2.1",
+                    "com.google.guava:guava:31.1-jre"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/auto/service/auto-service/1.0/auto-service-1.0.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/auto/service/auto-service/1.0/auto-service-1.0.jar"
+                ],
+                "packages": [
+                    "com.google.auto.service.processor"
+                ],
+                "sha256": "4ae44dd05b49a1109a463c0d2aaf920c24f76d1e996bb89f29481c4ff75ec526",
+                "url": "https://repo1.maven.org/maven2/com/google/auto/service/auto-service/1.0/auto-service-1.0.jar"
+            },
+            {
+                "coord": "com.google.auto.value:auto-value-annotations:1.9",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/auto/value/auto-value-annotations/1.9/auto-value-annotations-1.9.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/auto/value/auto-value-annotations/1.9/auto-value-annotations-1.9.jar"
+                ],
+                "packages": [
+                    "com.google.auto.value",
+                    "com.google.auto.value.extension.memoized",
+                    "com.google.auto.value.extension.serializable",
+                    "com.google.auto.value.extension.toprettystring"
+                ],
+                "sha256": "fa5469f4c44ee598a2d8f033ab0a9dcbc6498a0c5e0c998dfa0c2adf51358044",
+                "url": "https://repo1.maven.org/maven2/com/google/auto/value/auto-value-annotations/1.9/auto-value-annotations-1.9.jar"
+            },
+            {
+                "coord": "com.google.auto.value:auto-value:1.8.2",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/auto/value/auto-value/1.8.2/auto-value-1.8.2.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/auto/value/auto-value/1.8.2/auto-value-1.8.2.jar"
+                ],
+                "packages": [
+                    "autovalue.shaded.com.google$.auto.common",
+                    "autovalue.shaded.com.google$.auto.service",
+                    "autovalue.shaded.com.google$.common.annotations",
+                    "autovalue.shaded.com.google$.common.base",
+                    "autovalue.shaded.com.google$.common.collect",
+                    "autovalue.shaded.com.google$.common.hash",
+                    "autovalue.shaded.com.google$.common.math",
+                    "autovalue.shaded.com.google$.common.primitives",
+                    "autovalue.shaded.com.google$.common.reflect",
+                    "autovalue.shaded.com.google$.errorprone.annotations",
+                    "autovalue.shaded.com.google$.errorprone.annotations.concurrent",
+                    "autovalue.shaded.com.google$.escapevelocity",
+                    "autovalue.shaded.com.google$.j2objc.annotations",
+                    "autovalue.shaded.com.squareup.javapoet$",
+                    "autovalue.shaded.net.ltgt.gradle.incap$",
+                    "autovalue.shaded.org.checkerframework$.checker.nullness.qual",
+                    "autovalue.shaded.org.checkerframework$.framework.qual",
+                    "com.google.auto.value.extension",
+                    "com.google.auto.value.extension.memoized.processor",
+                    "com.google.auto.value.extension.serializable.processor",
+                    "com.google.auto.value.extension.serializable.serializer",
+                    "com.google.auto.value.extension.serializable.serializer.impl",
+                    "com.google.auto.value.extension.serializable.serializer.interfaces",
+                    "com.google.auto.value.extension.serializable.serializer.runtime",
+                    "com.google.auto.value.extension.toprettystring.processor",
+                    "com.google.auto.value.processor"
+                ],
+                "sha256": "2067b788d4c1c96fd621ad861053a5c4d8a801cfafc77fec20d49a6e9340a745",
+                "url": "https://repo1.maven.org/maven2/com/google/auto/value/auto-value/1.8.2/auto-value-1.8.2.jar"
+            },
+            {
+                "coord": "com.google.auto:auto-common:1.2.1",
+                "dependencies": [
+                    "com.google.guava:guava:31.1-jre"
+                ],
+                "directDependencies": [
+                    "com.google.guava:guava:31.1-jre"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/auto/auto-common/1.2.1/auto-common-1.2.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/auto/auto-common/1.2.1/auto-common-1.2.1.jar"
+                ],
+                "packages": [
+                    "com.google.auto.common"
+                ],
+                "sha256": "f43f29fe2a6ebaf04b2598cdeec32a4e346d49a9404e990f5fc19c19f3a28d0e",
+                "url": "https://repo1.maven.org/maven2/com/google/auto/auto-common/1.2.1/auto-common-1.2.1.jar"
+            },
+            {
+                "coord": "com.google.code.findbugs:jsr305:3.0.2",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/code/findbugs/jsr305/3.0.2/jsr305-3.0.2.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/code/findbugs/jsr305/3.0.2/jsr305-3.0.2.jar"
+                ],
+                "packages": [
+                    "javax.annotation",
+                    "javax.annotation.concurrent",
+                    "javax.annotation.meta"
+                ],
+                "sha256": "766ad2a0783f2687962c8ad74ceecc38a28b9f72a2d085ee438b7813e928d0c7",
+                "url": "https://repo1.maven.org/maven2/com/google/code/findbugs/jsr305/3.0.2/jsr305-3.0.2.jar"
+            },
+            {
+                "coord": "com.google.code.gson:gson:2.9.0",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/code/gson/gson/2.9.0/gson-2.9.0.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/code/gson/gson/2.9.0/gson-2.9.0.jar"
+                ],
+                "packages": [
+                    "com.google.gson",
+                    "com.google.gson.annotations",
+                    "com.google.gson.internal",
+                    "com.google.gson.internal.bind",
+                    "com.google.gson.internal.bind.util",
+                    "com.google.gson.internal.reflect",
+                    "com.google.gson.internal.sql",
+                    "com.google.gson.reflect",
+                    "com.google.gson.stream"
+                ],
+                "sha256": "c96d60551331a196dac54b745aa642cd078ef89b6f267146b705f2c2cbef052d",
+                "url": "https://repo1.maven.org/maven2/com/google/code/gson/gson/2.9.0/gson-2.9.0.jar"
+            },
+            {
+                "coord": "com.google.errorprone:error_prone_annotations:2.18.0",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/errorprone/error_prone_annotations/2.18.0/error_prone_annotations-2.18.0.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/errorprone/error_prone_annotations/2.18.0/error_prone_annotations-2.18.0.jar"
+                ],
+                "packages": [
+                    "com.google.errorprone.annotations",
+                    "com.google.errorprone.annotations.concurrent"
+                ],
+                "sha256": "9e6814cb71816988a4fd1b07a993a8f21bb7058d522c162b1de849e19bea54ae",
+                "url": "https://repo1.maven.org/maven2/com/google/errorprone/error_prone_annotations/2.18.0/error_prone_annotations-2.18.0.jar"
+            },
+            {
+                "coord": "com.google.errorprone:error_prone_type_annotations:2.18.0",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/errorprone/error_prone_type_annotations/2.18.0/error_prone_type_annotations-2.18.0.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/errorprone/error_prone_type_annotations/2.18.0/error_prone_type_annotations-2.18.0.jar"
+                ],
+                "packages": [
+                    "com.google.errorprone.annotations"
+                ],
+                "sha256": "d2ab73bc6807277f7463391504313e47bc3465ab1916339c8e82be633a9ab375",
+                "url": "https://repo1.maven.org/maven2/com/google/errorprone/error_prone_type_annotations/2.18.0/error_prone_type_annotations-2.18.0.jar"
+            },
+            {
+                "coord": "com.google.flogger:flogger-system-backend:0.5.1",
+                "dependencies": [
+                    "com.google.flogger:flogger:0.5.1",
+                    "org.checkerframework:checker-compat-qual:2.5.3"
+                ],
+                "directDependencies": [
+                    "com.google.flogger:flogger:0.5.1",
+                    "org.checkerframework:checker-compat-qual:2.5.3"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/flogger/flogger-system-backend/0.5.1/flogger-system-backend-0.5.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/flogger/flogger-system-backend/0.5.1/flogger-system-backend-0.5.1.jar"
+                ],
+                "packages": [
+                    "com.google.common.flogger.backend.system"
+                ],
+                "sha256": "685de33b53eb313049bbeee7f4b7a80dd09e8e754e96b048a3edab2cebb36442",
+                "url": "https://repo1.maven.org/maven2/com/google/flogger/flogger-system-backend/0.5.1/flogger-system-backend-0.5.1.jar"
+            },
+            {
+                "coord": "com.google.flogger:flogger:0.5.1",
+                "dependencies": [
+                    "com.google.flogger:flogger:0.5.1",
+                    "org.checkerframework:checker-compat-qual:2.5.3"
+                ],
+                "directDependencies": [
+                    "com.google.flogger:flogger:0.5.1",
+                    "org.checkerframework:checker-compat-qual:2.5.3"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/flogger/flogger/0.5.1/flogger-0.5.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/flogger/flogger/0.5.1/flogger-0.5.1.jar"
+                ],
+                "packages": [
+                    "com.google.common.flogger",
+                    "com.google.common.flogger.backend",
+                    "com.google.common.flogger.context",
+                    "com.google.common.flogger.parameter",
+                    "com.google.common.flogger.parser",
+                    "com.google.common.flogger.util"
+                ],
+                "sha256": "b5ecd1483e041197012786f749968a62063c1964d3ecfbf96ba92a95797bb8f5",
+                "url": "https://repo1.maven.org/maven2/com/google/flogger/flogger/0.5.1/flogger-0.5.1.jar"
+            },
+            {
+                "coord": "com.google.flogger:google-extensions:0.5.1",
+                "dependencies": [
+                    "com.google.flogger:flogger:0.5.1",
+                    "org.checkerframework:checker-compat-qual:2.5.3"
+                ],
+                "directDependencies": [
+                    "com.google.flogger:flogger:0.5.1"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/flogger/google-extensions/0.5.1/google-extensions-0.5.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/flogger/google-extensions/0.5.1/google-extensions-0.5.1.jar"
+                ],
+                "packages": [
+                    "com.google.common.flogger"
+                ],
+                "sha256": "8b0862cad85b9549f355fe383c6c63816d2f19529634e033ae06d0107ab110b9",
+                "url": "https://repo1.maven.org/maven2/com/google/flogger/google-extensions/0.5.1/google-extensions-0.5.1.jar"
+            },
+            {
+                "coord": "com.google.guava:failureaccess:1.0.1",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.jar"
+                ],
+                "packages": [
+                    "com.google.common.util.concurrent.internal"
+                ],
+                "sha256": "a171ee4c734dd2da837e4b16be9df4661afab72a41adaf31eb84dfdaf936ca26",
+                "url": "https://repo1.maven.org/maven2/com/google/guava/failureaccess/1.0.1/failureaccess-1.0.1.jar"
+            },
+            {
+                "coord": "com.google.guava:guava:31.1-jre",
+                "dependencies": [
+                    "com.google.code.findbugs:jsr305:3.0.2",
+                    "com.google.errorprone:error_prone_annotations:2.18.0",
+                    "com.google.guava:failureaccess:1.0.1",
+                    "com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava",
+                    "com.google.j2objc:j2objc-annotations:1.3",
+                    "org.checkerframework:checker-qual:3.19.0"
+                ],
+                "directDependencies": [
+                    "com.google.code.findbugs:jsr305:3.0.2",
+                    "com.google.errorprone:error_prone_annotations:2.18.0",
+                    "com.google.guava:failureaccess:1.0.1",
+                    "com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava",
+                    "com.google.j2objc:j2objc-annotations:1.3",
+                    "org.checkerframework:checker-qual:3.19.0"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/guava/guava/31.1-jre/guava-31.1-jre.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/guava/guava/31.1-jre/guava-31.1-jre.jar"
+                ],
+                "packages": [
+                    "com.google.common.annotations",
+                    "com.google.common.base",
+                    "com.google.common.base.internal",
+                    "com.google.common.cache",
+                    "com.google.common.collect",
+                    "com.google.common.escape",
+                    "com.google.common.eventbus",
+                    "com.google.common.graph",
+                    "com.google.common.hash",
+                    "com.google.common.html",
+                    "com.google.common.io",
+                    "com.google.common.math",
+                    "com.google.common.net",
+                    "com.google.common.primitives",
+                    "com.google.common.reflect",
+                    "com.google.common.util.concurrent",
+                    "com.google.common.xml",
+                    "com.google.thirdparty.publicsuffix"
+                ],
+                "sha256": "a42edc9cab792e39fe39bb94f3fca655ed157ff87a8af78e1d6ba5b07c4a00ab",
+                "url": "https://repo1.maven.org/maven2/com/google/guava/guava/31.1-jre/guava-31.1-jre.jar"
+            },
+            {
+                "coord": "com.google.guava:listenablefuture:9999.0-empty-to-avoid-conflict-with-guava",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/guava/listenablefuture/9999.0-empty-to-avoid-conflict-with-guava/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/guava/listenablefuture/9999.0-empty-to-avoid-conflict-with-guava/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar"
+                ],
+                "packages": [],
+                "sha256": "b372a037d4230aa57fbeffdef30fd6123f9c0c2db85d0aced00c91b974f33f99",
+                "url": "https://repo1.maven.org/maven2/com/google/guava/listenablefuture/9999.0-empty-to-avoid-conflict-with-guava/listenablefuture-9999.0-empty-to-avoid-conflict-with-guava.jar"
+            },
+            {
+                "coord": "com.google.j2objc:j2objc-annotations:1.3",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/google/j2objc/j2objc-annotations/1.3/j2objc-annotations-1.3.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/google/j2objc/j2objc-annotations/1.3/j2objc-annotations-1.3.jar"
+                ],
+                "packages": [
+                    "com.google.j2objc.annotations"
+                ],
+                "sha256": "21af30c92267bd6122c0e0b4d20cccb6641a37eaf956c6540ec471d584e64a7b",
+                "url": "https://repo1.maven.org/maven2/com/google/j2objc/j2objc-annotations/1.3/j2objc-annotations-1.3.jar"
+            },
+            {
+                "coord": "com.ryanharter.auto.value:auto-value-gson-extension:1.3.1",
+                "dependencies": [
+                    "com.google.auto.value:auto-value-annotations:1.9",
+                    "com.google.auto.value:auto-value:1.8.2",
+                    "com.google.code.gson:gson:2.9.0",
+                    "com.ryanharter.auto.value:auto-value-gson-runtime:1.3.1",
+                    "com.squareup:javapoet:1.12.0",
+                    "io.sweers.autotransient:autotransient:1.0.0"
+                ],
+                "directDependencies": [
+                    "com.google.auto.value:auto-value-annotations:1.9",
+                    "com.google.auto.value:auto-value:1.8.2",
+                    "com.google.code.gson:gson:2.9.0",
+                    "com.ryanharter.auto.value:auto-value-gson-runtime:1.3.1",
+                    "com.squareup:javapoet:1.12.0"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-extension/1.3.1/auto-value-gson-extension-1.3.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-extension/1.3.1/auto-value-gson-extension-1.3.1.jar"
+                ],
+                "packages": [
+                    "autovaluegson.shaded.com.google.auto.common",
+                    "autovaluegson.shaded.com.google.common.annotations",
+                    "autovaluegson.shaded.com.google.common.base",
+                    "autovaluegson.shaded.com.google.common.cache",
+                    "autovaluegson.shaded.com.google.common.collect",
+                    "autovaluegson.shaded.com.google.common.escape",
+                    "autovaluegson.shaded.com.google.common.eventbus",
+                    "autovaluegson.shaded.com.google.common.graph",
+                    "autovaluegson.shaded.com.google.common.hash",
+                    "autovaluegson.shaded.com.google.common.html",
+                    "autovaluegson.shaded.com.google.common.io",
+                    "autovaluegson.shaded.com.google.common.math",
+                    "autovaluegson.shaded.com.google.common.net",
+                    "autovaluegson.shaded.com.google.common.primitives",
+                    "autovaluegson.shaded.com.google.common.reflect",
+                    "autovaluegson.shaded.com.google.common.util.concurrent",
+                    "autovaluegson.shaded.com.google.common.xml",
+                    "com.ryanharter.auto.value.gson"
+                ],
+                "sha256": "261be84be30a56994e132d718a85efcd579197a2edb9426b84c5722c56955eca",
+                "url": "https://repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-extension/1.3.1/auto-value-gson-extension-1.3.1.jar"
+            },
+            {
+                "coord": "com.ryanharter.auto.value:auto-value-gson-factory:1.3.1",
+                "dependencies": [
+                    "com.google.auto.value:auto-value-annotations:1.9",
+                    "com.google.auto.value:auto-value:1.8.2",
+                    "com.google.code.gson:gson:2.9.0",
+                    "com.ryanharter.auto.value:auto-value-gson-extension:1.3.1",
+                    "com.ryanharter.auto.value:auto-value-gson-runtime:1.3.1",
+                    "com.squareup:javapoet:1.12.0",
+                    "io.sweers.autotransient:autotransient:1.0.0"
+                ],
+                "directDependencies": [
+                    "com.google.auto.value:auto-value-annotations:1.9",
+                    "com.google.code.gson:gson:2.9.0",
+                    "com.ryanharter.auto.value:auto-value-gson-extension:1.3.1",
+                    "com.squareup:javapoet:1.12.0"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-factory/1.3.1/auto-value-gson-factory-1.3.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-factory/1.3.1/auto-value-gson-factory-1.3.1.jar"
+                ],
+                "packages": [
+                    "autovaluegson.factory.shaded.com.google.auto.common",
+                    "autovaluegson.factory.shaded.com.google.common.annotations",
+                    "autovaluegson.factory.shaded.com.google.common.base",
+                    "autovaluegson.factory.shaded.com.google.common.cache",
+                    "autovaluegson.factory.shaded.com.google.common.collect",
+                    "autovaluegson.factory.shaded.com.google.common.escape",
+                    "autovaluegson.factory.shaded.com.google.common.eventbus",
+                    "autovaluegson.factory.shaded.com.google.common.graph",
+                    "autovaluegson.factory.shaded.com.google.common.hash",
+                    "autovaluegson.factory.shaded.com.google.common.html",
+                    "autovaluegson.factory.shaded.com.google.common.io",
+                    "autovaluegson.factory.shaded.com.google.common.math",
+                    "autovaluegson.factory.shaded.com.google.common.net",
+                    "autovaluegson.factory.shaded.com.google.common.primitives",
+                    "autovaluegson.factory.shaded.com.google.common.reflect",
+                    "autovaluegson.factory.shaded.com.google.common.util.concurrent",
+                    "autovaluegson.factory.shaded.com.google.common.xml",
+                    "com.ryanharter.auto.value.gson.factory"
+                ],
+                "sha256": "5a76c3d401c984999d59868f08df05a15613d1428f7764fed80b722e2a277f6c",
+                "url": "https://repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-factory/1.3.1/auto-value-gson-factory-1.3.1.jar"
+            },
+            {
+                "coord": "com.ryanharter.auto.value:auto-value-gson-runtime:1.3.1",
+                "dependencies": [
+                    "com.google.code.gson:gson:2.9.0",
+                    "io.sweers.autotransient:autotransient:1.0.0"
+                ],
+                "directDependencies": [
+                    "com.google.code.gson:gson:2.9.0",
+                    "io.sweers.autotransient:autotransient:1.0.0"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-runtime/1.3.1/auto-value-gson-runtime-1.3.1.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-runtime/1.3.1/auto-value-gson-runtime-1.3.1.jar"
+                ],
+                "packages": [
+                    "com.ryanharter.auto.value.gson",
+                    "com.ryanharter.auto.value.gson.internal"
+                ],
+                "sha256": "84ee23b7989d4bf19930b5bd3d03c0f2efb9e73bcee3a0208a9d1b2e1979c049",
+                "url": "https://repo1.maven.org/maven2/com/ryanharter/auto/value/auto-value-gson-runtime/1.3.1/auto-value-gson-runtime-1.3.1.jar"
+            },
+            {
+                "coord": "com.squareup:javapoet:1.12.0",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/com/squareup/javapoet/1.12.0/javapoet-1.12.0.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/com/squareup/javapoet/1.12.0/javapoet-1.12.0.jar"
+                ],
+                "packages": [
+                    "com.squareup.javapoet"
+                ],
+                "sha256": "2b70cdfa8c9e997b4007035a266c273c0df341f9c57c9d0b45a680ae3fd882db",
+                "url": "https://repo1.maven.org/maven2/com/squareup/javapoet/1.12.0/javapoet-1.12.0.jar"
+            },
+            {
+                "coord": "commons-collections:commons-collections:3.2.2",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar"
+                ],
+                "packages": [
+                    "org.apache.commons.collections",
+                    "org.apache.commons.collections.bag",
+                    "org.apache.commons.collections.bidimap",
+                    "org.apache.commons.collections.buffer",
+                    "org.apache.commons.collections.collection",
+                    "org.apache.commons.collections.comparators",
+                    "org.apache.commons.collections.functors",
+                    "org.apache.commons.collections.iterators",
+                    "org.apache.commons.collections.keyvalue",
+                    "org.apache.commons.collections.list",
+                    "org.apache.commons.collections.map",
+                    "org.apache.commons.collections.set"
+                ],
+                "sha256": "eeeae917917144a68a741d4c0dff66aa5c5c5fd85593ff217bced3fc8ca783b8",
+                "url": "https://repo1.maven.org/maven2/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar"
+            },
+            {
+                "coord": "commons-lang:commons-lang:2.6",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/commons-lang/commons-lang/2.6/commons-lang-2.6.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/commons-lang/commons-lang/2.6/commons-lang-2.6.jar"
+                ],
+                "packages": [
+                    "org.apache.commons.lang",
+                    "org.apache.commons.lang.builder",
+                    "org.apache.commons.lang.enum",
+                    "org.apache.commons.lang.enums",
+                    "org.apache.commons.lang.exception",
+                    "org.apache.commons.lang.math",
+                    "org.apache.commons.lang.mutable",
+                    "org.apache.commons.lang.reflect",
+                    "org.apache.commons.lang.text",
+                    "org.apache.commons.lang.time"
+                ],
+                "sha256": "50f11b09f877c294d56f24463f47d28f929cf5044f648661c0f0cfbae9a2f49c",
+                "url": "https://repo1.maven.org/maven2/commons-lang/commons-lang/2.6/commons-lang-2.6.jar"
+            },
+            {
+                "coord": "io.sweers.autotransient:autotransient:1.0.0",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/io/sweers/autotransient/autotransient/1.0.0/autotransient-1.0.0.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/io/sweers/autotransient/autotransient/1.0.0/autotransient-1.0.0.jar"
+                ],
+                "packages": [
+                    "io.sweers.autotransient"
+                ],
+                "sha256": "914ce84508410ee1419514925f93b1855a9f7a7b5b5d02fc07f411d2a45f1bba",
+                "url": "https://repo1.maven.org/maven2/io/sweers/autotransient/autotransient/1.0.0/autotransient-1.0.0.jar"
+            },
+            {
+                "coord": "org.apache.tomcat:tomcat-annotations-api:8.0.5",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/org/apache/tomcat/tomcat-annotations-api/8.0.5/tomcat-annotations-api-8.0.5.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/org/apache/tomcat/tomcat-annotations-api/8.0.5/tomcat-annotations-api-8.0.5.jar"
+                ],
+                "packages": [
+                    "javax.annotation",
+                    "javax.annotation.security",
+                    "javax.annotation.sql",
+                    "javax.ejb",
+                    "javax.persistence",
+                    "javax.xml.ws"
+                ],
+                "sha256": "748677bebb1651a313317dfd93e984ed8f8c9e345538fa8b0ab0cbb804631953",
+                "url": "https://repo1.maven.org/maven2/org/apache/tomcat/tomcat-annotations-api/8.0.5/tomcat-annotations-api-8.0.5.jar"
+            },
+            {
+                "coord": "org.apache.velocity:velocity:1.7",
+                "dependencies": [
+                    "commons-collections:commons-collections:3.2.2",
+                    "commons-lang:commons-lang:2.6"
+                ],
+                "directDependencies": [
+                    "commons-collections:commons-collections:3.2.2",
+                    "commons-lang:commons-lang:2.6"
+                ],
+                "file": "v1/https/repo1.maven.org/maven2/org/apache/velocity/velocity/1.7/velocity-1.7.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/org/apache/velocity/velocity/1.7/velocity-1.7.jar"
+                ],
+                "packages": [
+                    "org.apache.velocity",
+                    "org.apache.velocity.anakia",
+                    "org.apache.velocity.app",
+                    "org.apache.velocity.app.event",
+                    "org.apache.velocity.app.event.implement",
+                    "org.apache.velocity.app.tools",
+                    "org.apache.velocity.context",
+                    "org.apache.velocity.convert",
+                    "org.apache.velocity.exception",
+                    "org.apache.velocity.io",
+                    "org.apache.velocity.runtime",
+                    "org.apache.velocity.runtime.directive",
+                    "org.apache.velocity.runtime.log",
+                    "org.apache.velocity.runtime.parser",
+                    "org.apache.velocity.runtime.parser.node",
+                    "org.apache.velocity.runtime.resource",
+                    "org.apache.velocity.runtime.resource.loader",
+                    "org.apache.velocity.runtime.resource.util",
+                    "org.apache.velocity.runtime.visitor",
+                    "org.apache.velocity.servlet",
+                    "org.apache.velocity.texen",
+                    "org.apache.velocity.texen.ant",
+                    "org.apache.velocity.texen.util",
+                    "org.apache.velocity.util",
+                    "org.apache.velocity.util.introspection"
+                ],
+                "sha256": "ec92dae810034f4b46dbb16ef4364a4013b0efb24a8c5dd67435cae46a290d8e",
+                "url": "https://repo1.maven.org/maven2/org/apache/velocity/velocity/1.7/velocity-1.7.jar"
+            },
+            {
+                "coord": "org.checkerframework:checker-compat-qual:2.5.3",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/org/checkerframework/checker-compat-qual/2.5.3/checker-compat-qual-2.5.3.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/org/checkerframework/checker-compat-qual/2.5.3/checker-compat-qual-2.5.3.jar"
+                ],
+                "packages": [
+                    "org.checkerframework.checker.nullness.compatqual"
+                ],
+                "sha256": "d76b9afea61c7c082908023f0cbc1427fab9abd2df915c8b8a3e7a509bccbc6d",
+                "url": "https://repo1.maven.org/maven2/org/checkerframework/checker-compat-qual/2.5.3/checker-compat-qual-2.5.3.jar"
+            },
+            {
+                "coord": "org.checkerframework:checker-qual:3.19.0",
+                "dependencies": [],
+                "directDependencies": [],
+                "file": "v1/https/repo1.maven.org/maven2/org/checkerframework/checker-qual/3.19.0/checker-qual-3.19.0.jar",
+                "mirror_urls": [
+                    "https://repo1.maven.org/maven2/org/checkerframework/checker-qual/3.19.0/checker-qual-3.19.0.jar"
+                ],
+                "packages": [
+                    "org.checkerframework.checker.builder.qual",
+                    "org.checkerframework.checker.calledmethods.qual",
+                    "org.checkerframework.checker.compilermsgs.qual",
+                    "org.checkerframework.checker.fenum.qual",
+                    "org.checkerframework.checker.formatter.qual",
+                    "org.checkerframework.checker.guieffect.qual",
+                    "org.checkerframework.checker.i18n.qual",
+                    "org.checkerframework.checker.i18nformatter.qual",
+                    "org.checkerframework.checker.index.qual",
+                    "org.checkerframework.checker.initialization.qual",
+                    "org.checkerframework.checker.interning.qual",
+                    "org.checkerframework.checker.lock.qual",
+                    "org.checkerframework.checker.mustcall.qual",
+                    "org.checkerframework.checker.nullness.qual",
+                    "org.checkerframework.checker.optional.qual",
+                    "org.checkerframework.checker.propkey.qual",
+                    "org.checkerframework.checker.regex.qual",
+                    "org.checkerframework.checker.signature.qual",
+                    "org.checkerframework.checker.signedness.qual",
+                    "org.checkerframework.checker.tainting.qual",
+                    "org.checkerframework.checker.units.qual",
+                    "org.checkerframework.common.aliasing.qual",
+                    "org.checkerframework.common.initializedfields.qual",
+                    "org.checkerframework.common.reflection.qual",
+                    "org.checkerframework.common.returnsreceiver.qual",
+                    "org.checkerframework.common.subtyping.qual",
+                    "org.checkerframework.common.util.report.qual",
+                    "org.checkerframework.common.value.qual",
+                    "org.checkerframework.dataflow.qual",
+                    "org.checkerframework.framework.qual"
+                ],
+                "sha256": "a827c49183f3a632277d27a0a4673686cb341507447b9d570261094bd748aa68",
+                "url": "https://repo1.maven.org/maven2/org/checkerframework/checker-qual/3.19.0/checker-qual-3.19.0.jar"
+            }
+        ],
+        "version": "0.1.0"
+    }
+}
diff --git a/setup.bzl b/setup.bzl
index 807cf6f..aac6b3b 100644
--- a/setup.bzl
+++ b/setup.bzl
@@ -35,17 +35,18 @@
         http_archive,
         name = "rules_java",
         urls = [
-            "https://mirror.bazel.build/github.com/bazelbuild/rules_java/releases/download/4.0.0/rules_java-4.0.0.tar.gz",
-            "https://github.com/bazelbuild/rules_java/releases/download/4.0.0/rules_java-4.0.0.tar.gz",
+            "https://mirror.bazel.build/github.com/bazelbuild/rules_java/releases/download/5.3.5/rules_java-5.3.5.tar.gz",
+            "https://github.com/bazelbuild/rules_java/releases/download/5.3.5/rules_java-5.3.5.tar.gz",
         ],
-        sha256 = "34b41ec683e67253043ab1a3d1e8b7c61e4e8edefbcad485381328c934d072fe",
+        sha256 = "c73336802d0b4882e40770666ad055212df4ea62cfa6edf9cb0f9d29828a0934",
     )
     _include_if_not_defined(
         http_archive,
         name = "rules_license",
+        # TODO: Bazel@HEAD fails in the analysis phase with rules_license 0.0.4.
         urls = [
-            "https://mirror.bazel.build/github.com/bazelbuild/rules_license/releases/download/0.0.4/rules_license-0.0.4.tar.gz",
-            "https://github.com/bazelbuild/rules_license/releases/download/0.0.4/rules_license-0.0.4.tar.gz",
+            "https://mirror.bazel.build/github.com/bazelbuild/rules_license/releases/download/0.0.3/rules_license-0.0.3.tar.gz",
+            "https://github.com/bazelbuild/rules_license/releases/download/0.0.3/rules_license-0.0.3.tar.gz",
         ],
-        sha256 = "6157e1e68378532d0241ecd15d3c45f6e5cfd98fc10846045509fb2a7cc9e381",
+        sha256 = "00ccc0df21312c127ac4b12880ab0f9a26c1cff99442dc6c5a331750360de3c3",
     )
diff --git a/stardoc/BUILD b/stardoc/BUILD
index 1992806..045774f 100644
--- a/stardoc/BUILD
+++ b/stardoc/BUILD
@@ -25,7 +25,8 @@
     srcs = ["stardoc.bzl"],
     visibility = ["//visibility:public"],
     deps = [
-        "@bazel_skylib//:bzl_library",
+        "//stardoc/private:stardoc_lib",
+        "@rules_java//java:rules",
     ],
 )
 
@@ -50,14 +51,6 @@
 
 java_binary(
     name = "stardoc",
-    jvm_flags = [
-        # quiet warnings from com.google.protobuf.UnsafeUtil,
-        # see: https://github.com/google/protobuf/issues/3781
-        # TODO(cparsons): Remove once Stardoc has the fix.
-        "-XX:+IgnoreUnrecognizedVMOptions",
-        "--add-opens=java.base/java.nio=ALL-UNNAMED",
-        "--add-opens=java.base/java.lang=ALL-UNNAMED",
-    ],
     main_class = "com.google.devtools.build.skydoc.SkydocMain",
     runtime_deps = [
         ":prebuilt_stardoc_binary",
@@ -67,19 +60,11 @@
 java_import(
     name = "prebuilt_stardoc_binary",
     jars = ["stardoc_binary.jar"],
-    visibility = ["//visibility:private"],
+    visibility = ["//visibility:public"],
 )
 
 java_binary(
     name = "renderer",
-    jvm_flags = [
-        # quiet warnings from com.google.protobuf.UnsafeUtil,
-        # see: https://github.com/google/protobuf/issues/3781
-        # TODO(cparsons): Remove once Stardoc has the fix.
-        "-XX:+IgnoreUnrecognizedVMOptions",
-        "--add-opens=java.base/java.nio=ALL-UNNAMED",
-        "--add-opens=java.base/java.lang=ALL-UNNAMED",
-    ],
     main_class = "com.google.devtools.build.skydoc.renderer.RendererMain",
     runtime_deps = [
         ":prebuilt_renderer_binary",
diff --git a/stardoc/private/BUILD b/stardoc/private/BUILD
new file mode 100644
index 0000000..c0adf6d
--- /dev/null
+++ b/stardoc/private/BUILD
@@ -0,0 +1,7 @@
+load("@bazel_skylib//:bzl_library.bzl", "bzl_library")
+
+bzl_library(
+    name = "stardoc_lib",
+    srcs = ["stardoc.bzl"],
+    visibility = ["//stardoc:__pkg__"],
+)
diff --git a/stardoc/private/stardoc.bzl b/stardoc/private/stardoc.bzl
new file mode 100644
index 0000000..204af38
--- /dev/null
+++ b/stardoc/private/stardoc.bzl
@@ -0,0 +1,160 @@
+# Copyright 2018 The Bazel Authors. All rights reserved.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+#    http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+"""Starlark rule for stardoc: a documentation generator tool written in Java."""
+
+def _stardoc_impl(ctx):
+    """Implementation of the stardoc rule."""
+    for semantic_flag in ctx.attr.semantic_flags:
+        if not semantic_flag.startswith("--"):
+            fail("semantic_flags entry '%s' must start with '--'" % semantic_flag)
+    out_file = ctx.outputs.out
+    stardoc_args = ctx.actions.args()
+    stardoc_args.add("--input=" + str(ctx.file.input.owner))
+    stardoc_args.add("--workspace_name=" + ctx.workspace_name)
+    stardoc_args.add_all(
+        ctx.attr.symbol_names,
+        format_each = "--symbols=%s",
+        omit_if_empty = True,
+    )
+    stardoc_args.add_all(ctx.attr.semantic_flags)
+    stardoc = ctx.executable.stardoc
+
+    if ctx.attr.format == "proto":
+        stardoc_args.add("--output=" + out_file.path)
+        ctx.actions.run(
+            outputs = [out_file],
+            executable = stardoc,
+            arguments = [stardoc_args],
+            mnemonic = "Stardoc",
+            progress_message = ("Generating Starlark doc for %s" %
+                                (ctx.label.name)),
+        )
+    elif ctx.attr.format == "markdown":
+        proto_file = ctx.actions.declare_file(ctx.label.name + ".raw", sibling = out_file)
+        stardoc_args.add("--output=" + proto_file.path)
+        ctx.actions.run(
+            outputs = [proto_file],
+            executable = stardoc,
+            arguments = [stardoc_args],
+            mnemonic = "Stardoc",
+            progress_message = ("Generating proto for Starlark doc for %s" %
+                                (ctx.label.name)),
+        )
+        renderer_args = ctx.actions.args()
+        renderer_args.add("--input=" + str(proto_file.path))
+        renderer_args.add("--output=" + str(ctx.outputs.out.path))
+        renderer_args.add("--aspect_template=" + str(ctx.file.aspect_template.path))
+        renderer_args.add("--header_template=" + str(ctx.file.header_template.path))
+        renderer_args.add("--func_template=" + str(ctx.file.func_template.path))
+        renderer_args.add("--provider_template=" + str(ctx.file.provider_template.path))
+        renderer_args.add("--rule_template=" + str(ctx.file.rule_template.path))
+        renderer = ctx.executable.renderer
+        ctx.actions.run(
+            outputs = [out_file],
+            inputs = [proto_file, ctx.file.aspect_template, ctx.file.header_template, ctx.file.func_template, ctx.file.provider_template, ctx.file.rule_template],
+            executable = renderer,
+            arguments = [renderer_args],
+            mnemonic = "Renderer",
+            progress_message = ("Converting proto format of %s to markdown format" %
+                                (ctx.label.name)),
+        )
+
+    # Work around default outputs not getting captured by sh_binary:
+    # https://github.com/bazelbuild/bazel/issues/15043.
+    # See discussion in https://github.com/bazelbuild/stardoc/pull/139.
+    outputs = [out_file]
+    return [DefaultInfo(files = depset(outputs), runfiles = ctx.runfiles(files = outputs))]
+
+stardoc = rule(
+    _stardoc_impl,
+    doc = """
+Generates documentation for starlark skylark rule definitions in a target starlark file.
+""",
+    attrs = {
+        "input": attr.label(
+            doc = "The starlark file to generate documentation for.",
+            allow_single_file = [".bzl"],
+            mandatory = True,
+        ),
+        "out": attr.output(
+            doc = "The (markdown) file to which documentation will be output.",
+            mandatory = True,
+        ),
+        "format": attr.string(
+            doc = "The format of the output file. Valid values: 'markdown' or 'proto'.",
+            values = ["markdown", "proto"],
+            mandatory = True,
+        ),
+        "symbol_names": attr.string_list(
+            doc = """
+A list of symbol names to generate documentation for. These should correspond to
+the names of rule definitions in the input file. If this list is empty, then
+documentation for all exported rule definitions will be generated.
+""",
+            mandatory = True,
+        ),
+        "semantic_flags": attr.string_list(
+            doc = """
+A list of canonical flags to affect Starlark semantics for the Starlark interpretter
+during documentation generation. This should only be used to maintain compatibility with
+non-default semantic flags required to use the given Starlark symbols.
+
+For example, if `//foo:bar.bzl` does not build except when a user would specify
+`--incompatible_foo_semantic=false`, then this attribute should contain
+"--incompatible_foo_semantic=false".
+""",
+            mandatory = True,
+        ),
+        "stardoc": attr.label(
+            doc = "The location of the stardoc tool.",
+            allow_files = True,
+            cfg = "exec",
+            executable = True,
+            mandatory = True,
+        ),
+        "renderer": attr.label(
+            doc = "The location of the renderer tool.",
+            allow_files = True,
+            cfg = "exec",
+            executable = True,
+            mandatory = True,
+        ),
+        "aspect_template": attr.label(
+            doc = "The input file template for generating documentation of aspects.",
+            allow_single_file = [".vm"],
+            mandatory = True,
+        ),
+        "header_template": attr.label(
+            doc = "The input file template for the header of the output documentation.",
+            allow_single_file = [".vm"],
+            mandatory = True,
+        ),
+        "func_template": attr.label(
+            doc = "The input file template for generating documentation of functions.",
+            allow_single_file = [".vm"],
+            mandatory = True,
+        ),
+        "provider_template": attr.label(
+            doc = "The input file template for generating documentation of providers.",
+            allow_single_file = [".vm"],
+            mandatory = True,
+        ),
+        "rule_template": attr.label(
+            doc = "The input file template for generating documentation of rules.",
+            allow_single_file = [".vm"],
+            mandatory = True,
+        ),
+    },
+)
diff --git a/stardoc/renderer_binary.jar b/stardoc/renderer_binary.jar
index d822ecc..f182b9f 100755
--- a/stardoc/renderer_binary.jar
+++ b/stardoc/renderer_binary.jar
Binary files differ
diff --git a/stardoc/stardoc.bzl b/stardoc/stardoc.bzl
index 61848d7..1728dfc 100644
--- a/stardoc/stardoc.bzl
+++ b/stardoc/stardoc.bzl
@@ -14,190 +14,80 @@
 
 """Starlark rule for stardoc: a documentation generator tool written in Java."""
 
-load("@bazel_skylib//:bzl_library.bzl", "StarlarkLibraryInfo")
+load("@rules_java//java:defs.bzl", "java_binary")
+load("//stardoc/private:stardoc.bzl", _stardoc = "stardoc")
 
-def _root_from_file(f):
-    """Given a file, returns the root path of that file."""
-    return f.root.path or "."
+def stardoc(
+        *,
+        name,
+        input,
+        out,
+        deps = [],
+        format = "markdown",
+        symbol_names = [],
+        semantic_flags = [],
+        stardoc = Label("//stardoc:prebuilt_stardoc_binary"),
+        renderer = Label("//stardoc:renderer"),
+        aspect_template = Label("//stardoc:templates/markdown_tables/aspect.vm"),
+        func_template = Label("//stardoc:templates/markdown_tables/func.vm"),
+        header_template = Label("//stardoc:templates/markdown_tables/header.vm"),
+        provider_template = Label("//stardoc:templates/markdown_tables/provider.vm"),
+        rule_template = Label("//stardoc:templates/markdown_tables/rule.vm"),
+        **kwargs):
+    """Generates documentation for exported starlark rule definitions in a target starlark file.
 
-def _stardoc_impl(ctx):
-    """Implementation of the stardoc rule."""
-    for semantic_flag in ctx.attr.semantic_flags:
-        if not semantic_flag.startswith("--"):
-            fail("semantic_flags entry '%s' must start with '--'" % semantic_flag)
-    out_file = ctx.outputs.out
-    input_files = depset(direct = [ctx.file.input], transitive = [
-        dep[StarlarkLibraryInfo].transitive_srcs
-        for dep in ctx.attr.deps
-    ])
-    stardoc_args = ctx.actions.args()
-    stardoc_args.add("--input=" + str(ctx.file.input.owner))
-    stardoc_args.add("--workspace_name=" + ctx.workspace_name)
-    stardoc_args.add_all(
-        ctx.attr.symbol_names,
-        format_each = "--symbols=%s",
-        omit_if_empty = True,
+    Args:
+      name: The name of the stardoc target.
+      input: The starlark file to generate documentation for (mandatory).
+      out: The file to which documentation will be output (mandatory).
+      deps: A list of bzl_library dependencies which the input depends on.
+      format: The format of the output file. Valid values: 'markdown' or 'proto'.
+      symbol_names: A list of symbol names to generate documentation for. These should correspond to the names of rule
+        definitions in the input file. If this list is empty, then documentation for all exported rule definitions will
+        be generated.
+      semantic_flags: A list of canonical flags to affect Starlark semantics for the Starlark interpreter during
+        documentation generation. This should only be used to maintain compatibility with non-default semantic flags
+        required to use the given Starlark symbols.
+
+        For example, if `//foo:bar.bzl` does not build except when a user would specify
+        `--incompatible_foo_semantic=false`, then this attribute should contain
+        "--incompatible_foo_semantic=false".
+      stardoc: The location of the stardoc tool.
+      renderer: The location of the renderer tool.
+      aspect_template: The input file template for generating documentation of aspects
+      header_template: The input file template for the header of the output documentation.
+      func_template: The input file template for generating documentation of functions.
+      provider_template: The input file template for generating documentation of providers.
+      rule_template: The input file template for generating documentation of rules.
+      **kwargs: Further arguments to pass to stardoc.
+    """
+
+    stardoc_with_runfiles_name = name + "_stardoc"
+
+    testonly = {"testonly": kwargs["testonly"]} if "testonly" in kwargs else {}
+    java_binary(
+        name = stardoc_with_runfiles_name,
+        main_class = "com.google.devtools.build.skydoc.SkydocMain",
+        runtime_deps = [stardoc],
+        data = [input] + deps,
+        tags = ["manual"],
+        visibility = ["//visibility:private"],
+        **testonly
     )
 
-    # TODO(cparsons): Note that use of dep_roots alone does not guarantee
-    # the correct file is loaded. If two files exist under the same path
-    # but are under different roots, it is possible that Stardoc loads the
-    # one that is not explicitly an input to this action (if sandboxing is
-    # disabled). The correct way to resolve this is to explicitly specify
-    # the full set of transitive dependency Starlark files as action args
-    # (maybe using a param file), but this requires some work.
-    stardoc_args.add_all(
-        input_files,
-        format_each = "--dep_roots=%s",
-        map_each = _root_from_file,
-        omit_if_empty = True,
-        uniquify = True,
+    _stardoc(
+        name = name,
+        input = input,
+        out = out,
+        format = format,
+        symbol_names = symbol_names,
+        semantic_flags = semantic_flags,
+        stardoc = stardoc_with_runfiles_name,
+        renderer = renderer,
+        aspect_template = aspect_template,
+        func_template = func_template,
+        header_template = header_template,
+        provider_template = provider_template,
+        rule_template = rule_template,
+        **kwargs
     )
-
-    # Needed in case some files are referenced across local repository
-    # namespace. For example, consider a file under a nested local repository @bar
-    # rooted under ./foo/bar/WORKSPACE. Consider a stardoc target 'lib_doc' under
-    # foo/bar/BUILD to document foo/bar/lib.bzl.
-    # The stardoc target references @bar//:lib.bzl (which appears just as :lib.bzl), but the
-    # actual build is taking place in the root repository, thus the source file
-    # is present under external/bar/lib.bzl.
-    stardoc_args.add(
-        "--dep_roots=external/" + ctx.workspace_name,
-    )
-    stardoc_args.add_all(ctx.attr.semantic_flags)
-    stardoc = ctx.executable.stardoc
-
-    if ctx.attr.format == "proto":
-        stardoc_args.add("--output=" + out_file.path)
-        ctx.actions.run(
-            outputs = [out_file],
-            inputs = input_files,
-            executable = stardoc,
-            arguments = [stardoc_args],
-            mnemonic = "Stardoc",
-            progress_message = ("Generating Starlark doc for %s" %
-                                (ctx.label.name)),
-        )
-    elif ctx.attr.format == "markdown":
-        proto_file = ctx.actions.declare_file(ctx.label.name + ".raw", sibling = out_file)
-        stardoc_args.add("--output=" + proto_file.path)
-        ctx.actions.run(
-            outputs = [proto_file],
-            inputs = input_files,
-            executable = stardoc,
-            arguments = [stardoc_args],
-            mnemonic = "Stardoc",
-            progress_message = ("Generating proto for Starlark doc for %s" %
-                                (ctx.label.name)),
-        )
-        renderer_args = ctx.actions.args()
-        renderer_args.add("--input=" + str(proto_file.path))
-        renderer_args.add("--output=" + str(ctx.outputs.out.path))
-        renderer_args.add("--aspect_template=" + str(ctx.file.aspect_template.path))
-        renderer_args.add("--header_template=" + str(ctx.file.header_template.path))
-        renderer_args.add("--func_template=" + str(ctx.file.func_template.path))
-        renderer_args.add("--provider_template=" + str(ctx.file.provider_template.path))
-        renderer_args.add("--rule_template=" + str(ctx.file.rule_template.path))
-        renderer = ctx.executable.renderer
-        ctx.actions.run(
-            outputs = [out_file],
-            inputs = [proto_file, ctx.file.aspect_template, ctx.file.header_template, ctx.file.func_template, ctx.file.provider_template, ctx.file.rule_template],
-            executable = renderer,
-            arguments = [renderer_args],
-            mnemonic = "Renderer",
-            progress_message = ("Converting proto format of %s to markdown format" %
-                                (ctx.label.name)),
-        )
-
-    # Work around default outputs not getting captured by sh_binary:
-    # https://github.com/bazelbuild/bazel/issues/15043.
-    # See discussion in https://github.com/bazelbuild/stardoc/pull/139.
-    outputs = [out_file]
-    return [DefaultInfo(files = depset(outputs), runfiles = ctx.runfiles(files = outputs))]
-
-stardoc = rule(
-    _stardoc_impl,
-    doc = """
-Generates documentation for exported skylark rule definitions in a target starlark file.
-
-This rule is an experimental replacement for the existing skylark_doc rule.
-""",
-    attrs = {
-        "input": attr.label(
-            doc = "The starlark file to generate documentation for.",
-            allow_single_file = [".bzl"],
-        ),
-        "deps": attr.label_list(
-            doc = "A list of bzl_library dependencies which the input depends on.",
-            providers = [StarlarkLibraryInfo],
-        ),
-        "format": attr.string(
-            doc = "The format of the output file. Valid values: 'markdown' or 'proto'.",
-            default = "markdown",
-            values = ["markdown", "proto"],
-        ),
-        "out": attr.output(
-            doc = "The (markdown) file to which documentation will be output.",
-            mandatory = True,
-        ),
-        "symbol_names": attr.string_list(
-            doc = """
-A list of symbol names to generate documentation for. These should correspond to
-the names of rule definitions in the input file. If this list is empty, then
-documentation for all exported rule definitions will be generated.
-""",
-            default = [],
-        ),
-        "semantic_flags": attr.string_list(
-            doc = """
-A list of canonical flags to affect Starlark semantics for the Starlark interpretter
-during documentation generation. This should only be used to maintain compatibility with
-non-default semantic flags required to use the given Starlark symbols.
-
-For example, if `//foo:bar.bzl` does not build except when a user would specify
-`--incompatible_foo_semantic=false`, then this attribute should contain
-"--incompatible_foo_semantic=false".
-""",
-            default = [],
-        ),
-        "stardoc": attr.label(
-            doc = "The location of the stardoc tool.",
-            allow_files = True,
-            default = Label("//stardoc:stardoc"),
-            cfg = "exec",
-            executable = True,
-        ),
-        "renderer": attr.label(
-            doc = "The location of the renderer tool.",
-            allow_files = True,
-            default = Label("//stardoc:renderer"),
-            cfg = "exec",
-            executable = True,
-        ),
-        "aspect_template": attr.label(
-            doc = "The input file template for generating documentation of aspects.",
-            allow_single_file = [".vm"],
-            default = Label("//stardoc:templates/markdown_tables/aspect.vm"),
-        ),
-        "header_template": attr.label(
-            doc = "The input file template for the header of the output documentation.",
-            allow_single_file = [".vm"],
-            default = Label("//stardoc:templates/markdown_tables/header.vm"),
-        ),
-        "func_template": attr.label(
-            doc = "The input file template for generating documentation of functions.",
-            allow_single_file = [".vm"],
-            default = Label("//stardoc:templates/markdown_tables/func.vm"),
-        ),
-        "provider_template": attr.label(
-            doc = "The input file template for generating documentation of providers.",
-            allow_single_file = [".vm"],
-            default = Label("//stardoc:templates/markdown_tables/provider.vm"),
-        ),
-        "rule_template": attr.label(
-            doc = "The input file template for generating documentation of rules.",
-            allow_single_file = [".vm"],
-            default = Label("//stardoc:templates/markdown_tables/rule.vm"),
-        ),
-    },
-)
diff --git a/stardoc/stardoc_binary.jar b/stardoc/stardoc_binary.jar
index 47b6874..dee55d5 100755
--- a/stardoc/stardoc_binary.jar
+++ b/stardoc/stardoc_binary.jar
Binary files differ
diff --git a/test/stardoc_test.bzl b/test/stardoc_test.bzl
index 8a18b52..cb356af 100644
--- a/test/stardoc_test.bzl
+++ b/test/stardoc_test.bzl
@@ -59,7 +59,7 @@
         lib_name = "%s_lib" % name,
         input_file = input_file,
         golden_file = golden_file,
-        stardoc_bin = "@io_bazel//src/main/java/com/google/devtools/build/skydoc",
+        stardoc_bin = "@io_bazel//src/main/java/com/google/devtools/build/skydoc:skydoc_deploy.jar",
         renderer_bin = "@io_bazel//src/main/java/com/google/devtools/build/skydoc/renderer",
         test = test,
         **kwargs
@@ -70,7 +70,7 @@
         lib_name = "%s_lib" % name,
         input_file = input_file,
         golden_file = golden_file,
-        stardoc_bin = "@io_bazel//src/main/java/com/google/devtools/build/skydoc",
+        stardoc_bin = "@io_bazel//src/main/java/com/google/devtools/build/skydoc:skydoc_deploy.jar",
         renderer_bin = "@io_bazel//src/main/java/com/google/devtools/build/skydoc/renderer",
         test = test,
         **kwargs