Skip to content

Commit

Permalink
Remove migration tags pollution in the java_* rules
Browse files Browse the repository at this point in the history
Given the alternative mechanism of inspecting the callstack for the invocation location, this is no longer needed.

PiperOrigin-RevId: 610399903
Change-Id: I29a2c222c58b13e2f09b00e9a4741a32110fa9ab
  • Loading branch information
hvadehra authored and copybara-github committed Feb 26, 2024
1 parent 3c34c81 commit 01c4009
Show file tree
Hide file tree
Showing 12 changed files with 10 additions and 54 deletions.
4 changes: 1 addition & 3 deletions java/java_binary.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_binary rule"""

load("//java/private:add_tags.bzl", "add_tags")

# Do not touch: This line marks the end of loads; needed for PR importing.

def java_binary(**attrs):
Expand All @@ -27,4 +25,4 @@ def java_binary(**attrs):
"""

# buildifier: disable=native-java
native.java_binary(**add_tags(attrs))
native.java_binary(**attrs)
4 changes: 1 addition & 3 deletions java/java_import.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_import rule"""

load("//java/private:add_tags.bzl", "add_tags")

def java_import(**attrs):
"""Bazel java_import rule.
Expand All @@ -25,4 +23,4 @@ def java_import(**attrs):
"""

# buildifier: disable=native-java
native.java_import(**add_tags(attrs))
native.java_import(**attrs)
4 changes: 1 addition & 3 deletions java/java_library.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_library rule"""

load("//java/private:add_tags.bzl", "add_tags")

# Do not touch: This line marks the end of loads; needed for PR importing.

def java_library(**attrs):
Expand All @@ -27,4 +25,4 @@ def java_library(**attrs):
"""

# buildifier: disable=native-java
native.java_library(**add_tags(attrs))
native.java_library(**attrs)
4 changes: 1 addition & 3 deletions java/java_plugin.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_plugin rule"""

load("//java/private:add_tags.bzl", "add_tags")

def java_plugin(**attrs):
"""Bazel java_plugin rule.
Expand All @@ -25,4 +23,4 @@ def java_plugin(**attrs):
"""

# buildifier: disable=native-java
native.java_plugin(**add_tags(attrs))
native.java_plugin(**attrs)
4 changes: 1 addition & 3 deletions java/java_test.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_test rule"""

load("//java/private:add_tags.bzl", "add_tags")

# Do not touch: This line marks the end of loads; needed for PR importing.

def java_test(**attrs):
Expand All @@ -27,4 +25,4 @@ def java_test(**attrs):
"""

# buildifier: disable=native-java
native.java_test(**add_tags(attrs))
native.java_test(**attrs)
1 change: 0 additions & 1 deletion java/private/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ licenses(["notice"])
bzl_library(
name = "private",
srcs = [
"add_tags.bzl",
"native.bzl",
],
visibility = ["//java:__subpackages__"],
Expand Down
23 changes: 0 additions & 23 deletions java/private/add_tags.bzl

This file was deleted.

4 changes: 1 addition & 3 deletions java/proto/java_lite_proto_library.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_lite_proto_library rule"""

load("//java/private:add_tags.bzl", "add_tags")

def java_lite_proto_library(**attrs):
"""Bazel java_lite_proto_library rule.
Expand All @@ -25,4 +23,4 @@ def java_lite_proto_library(**attrs):
"""

# buildifier: disable=native-java
native.java_lite_proto_library(**add_tags(attrs))
native.java_lite_proto_library(**attrs)
4 changes: 1 addition & 3 deletions java/proto/java_proto_library.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_proto_library rule"""

load("//java/private:add_tags.bzl", "add_tags")

def java_proto_library(**attrs):
"""Bazel java_proto_library rule.
Expand All @@ -25,4 +23,4 @@ def java_proto_library(**attrs):
"""

# buildifier: disable=native-java
native.java_proto_library(**add_tags(attrs))
native.java_proto_library(**attrs)
4 changes: 1 addition & 3 deletions java/toolchains/java_package_configuration.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_package_configuration rule"""

load("//java/private:add_tags.bzl", "add_tags")

def java_package_configuration(**attrs):
"""Bazel java_package_configuration rule.
Expand All @@ -25,4 +23,4 @@ def java_package_configuration(**attrs):
"""

# buildifier: disable=native-java
native.java_package_configuration(**add_tags(attrs))
native.java_package_configuration(**attrs)
4 changes: 1 addition & 3 deletions java/toolchains/java_runtime.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_runtime rule"""

load("//java/private:add_tags.bzl", "add_tags")

def java_runtime(**attrs):
"""Bazel java_runtime rule.
Expand All @@ -25,4 +23,4 @@ def java_runtime(**attrs):
"""

# buildifier: disable=native-java
native.java_runtime(**add_tags(attrs))
native.java_runtime(**attrs)
4 changes: 1 addition & 3 deletions java/toolchains/java_toolchain.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,6 @@
# limitations under the License.
"""java_toolchain rule"""

load("//java/private:add_tags.bzl", "add_tags")

def java_toolchain(**attrs):
"""Bazel java_toolchain rule.
Expand All @@ -25,4 +23,4 @@ def java_toolchain(**attrs):
"""

# buildifier: disable=native-java
native.java_toolchain(**add_tags(attrs))
native.java_toolchain(**attrs)

0 comments on commit 01c4009

Please sign in to comment.