Repository navigation
Separate shared PMD configuration from toolchain selection - #106
Merged
Merged
Conversation
Bencodes
force-pushed
the
move-shared-pmd-policy-into-toolchain-profiles
branch
2 times, most recently
from
September 13, 2026 19:07
b0b5e8b to
b079a90
Compare
Configure rulesets, priority, violation policy, concurrency, JVM flags and the exec wrapper in selected or registered profiles. Keep source metadata and report outputs on native PMD rules, migrate fixtures and documentation, and cover profile selection and isolation with declarative Bazel tests.
Bencodes
force-pushed
the
move-shared-pmd-policy-into-toolchain-profiles
branch
from
November 8, 2026 02:59
cb56954 to
299c0b6
Compare
Replace the toolchain's default_config with the @rules_pmd//pmd:config label flag so only the root module can set the repository-wide default. Move fail_on_violation back to pmd/pmd_test as a per-target choice. Validate PmdConfigInfo fields and restrict rules_minimum_priority to 1-5. Name the selected config in the empty-rulesets error. Tests assert flag/value pairs, cover both select() branches, decode Bazel 8 middleman names fully, and drop assertions that could not fail. README documents cross-package configs, the label flag, and --host_jvmopt for JVM options.
Targets without config fall back to the registered toolchain's default_config again. The empty-rulesets error names that config's label.
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.
pmd_configletspmdandpmd_testshare analysis settings without registering a separate toolchain. Bazel still selects the executable.Migration: Move
rulesets,rules_minimum_priority, andthreads_countinto apmd_configtarget. Reference it withconfig = ":policy", or set the toolchain'sdefault_configfor repository-wide use. An explicit config replaces the default; settings do not merge.fail_on_violationstays on each target. Use Bazel's--host_jvmoptinstead of the toolchain'sjvm_flags.docs/*.mdwere updated by hand because stardoc does not build locally; regenerate withdocs/generate.shbefore merging.