diff --git a/.bazelrc b/.bazelrc index e7fe9bb..96d0eaa 100644 --- a/.bazelrc +++ b/.bazelrc @@ -1,3 +1,4 @@ common --experimental_google_legacy_api +common --check_visibility=false try-import %workspace%/.bazelrc.user diff --git a/MODULE.bazel b/MODULE.bazel index cdd6dc4..0970985 100644 --- a/MODULE.bazel +++ b/MODULE.bazel @@ -4,6 +4,7 @@ module( compatibility_level = 1, ) +bazel_dep(name = "rules_android", version = "0.6.0") bazel_dep(name = "rules_java", version = "8.6.3") bazel_dep(name = "rules_jvm_external", version = "5.3") bazel_dep(name = "rules_kotlin", version = "2.1.0") diff --git a/docs/rules.md b/docs/rules.md index 3d58279..237ad0b 100644 --- a/docs/rules.md +++ b/docs/rules.md @@ -7,6 +7,8 @@ Android Lint rules ## android_lint
+load("@rules_android_lint//rules:defs.bzl", "android_lint") + android_lint(name, deps, srcs, android_lint_config, autofix, custom_rules, disable_checks, enable_checks, is_test_sources, lib, manifest, resource_files, warnings_as_errors)@@ -38,6 +40,8 @@ android_lint(name, +load("@rules_android_lint//rules:defs.bzl", "android_lint_test") + android_lint_test(name, deps, srcs, android_lint_config, autofix, baseline, custom_rules, disable_checks, enable_checks, is_test_sources, lib, manifest, resource_files, warnings_as_errors) @@ -71,6 +75,8 @@ android_lint_test(name, output) @@ -78,7 +84,6 @@ Info needed to evaluate lint results **FIELDS** - | Name | Description | | :------------- | :------------- | | output | The Android Lint baseline output | diff --git a/rules/BUILD.bazel b/rules/BUILD.bazel index dd6ef00..8197ab9 100644 --- a/rules/BUILD.bazel +++ b/rules/BUILD.bazel @@ -72,6 +72,7 @@ bzl_library( deps = [ ":collect_aar_outputs_aspect", "@bazel_skylib//lib:dicts", + "@rules_android//providers:providers_bzl", "@rules_java//java:rules", "@rules_java//java/private:proto_support", ], diff --git a/rules/impl.bzl b/rules/impl.bzl index f4f8258..d4011f5 100644 --- a/rules/impl.bzl +++ b/rules/impl.bzl @@ -1,7 +1,15 @@ """Rule implementation for Android Lint """ -load("@rules_java//java/common:java_info.bzl", "JavaInfo") +load( + "@rules_android//providers:providers.bzl", + "AndroidLibraryAarInfo", + "AndroidLibraryResourceClassJarProvider", +) +load( + "@rules_java//java:defs.bzl", + "JavaInfo", +) load( ":collect_aar_outputs_aspect.bzl", _AndroidLintAARInfo = "AndroidLintAARInfo",