Prevent buildifier warning in WORKSPACE file.

PiperOrigin-RevId: 354993799
Change-Id: If1ed5db7cb3f9ba82b179ed9070b027088ca0493
This commit is contained in:
Christian Sigg 2021-02-01 11:59:46 -08:00 committed by TensorFlower Gardener
parent 808fc11053
commit e70a5f4243
5 changed files with 25 additions and 9 deletions

View File

@ -2,22 +2,22 @@ workspace(name = "org_tensorflow")
# Initialize the TensorFlow repository and all dependencies.
#
# The cascade of load() statements and workspace() calls works around the
# The cascade of load() statements and tf_workspace?() calls works around the
# restriction that load() statements need to be at the top of .bzl files.
# E.g. we can not retrieve a new repository with http_archive and then load()
# a macro from that repository in the same file.
load("@//tensorflow:workspace3.bzl", "workspace")
load("@//tensorflow:workspace3.bzl", "tf_workspace3")
workspace()
tf_workspace3()
load("@//tensorflow:workspace2.bzl", "workspace")
load("@//tensorflow:workspace2.bzl", "tf_workspace2")
workspace()
tf_workspace2()
load("@//tensorflow:workspace1.bzl", "workspace")
load("@//tensorflow:workspace1.bzl", "tf_workspace1")
workspace()
tf_workspace1()
load("@//tensorflow:workspace0.bzl", "workspace")
load("@//tensorflow:workspace0.bzl", "tf_workspace0")
workspace()
tf_workspace0()

View File

@ -76,3 +76,7 @@ def workspace():
grpc_extra_deps()
config_googleapis()
# Alias so it can be loaded without assigning to a different symbol to prevent
# shadowing previous loads and trigger a buildifier warning.
tf_workspace0 = workspace

View File

@ -14,3 +14,7 @@ def workspace():
android_configure(name = "local_config_android")
grpc_deps()
# Alias so it can be loaded without assigning to a different symbol to prevent
# shadowing previous loads and trigger a buildifier warning.
tf_workspace1 = workspace

View File

@ -11,3 +11,7 @@ def workspace():
# Load tf_repositories() before loading dependencies for other repository so
# that dependencies like com_google_protobuf won't be overridden.
tf_repositories()
# Alias so it can be loaded without assigning to a different symbol to prevent
# shadowing previous loads and trigger a buildifier warning.
tf_workspace2 = workspace

View File

@ -12,3 +12,7 @@ def workspace():
"https://github.com/bazelbuild/rules_closure/archive/308b05b2419edb5c8ee0471b67a40403df940149.tar.gz", # 2019-06-13
],
)
# Alias so it can be loaded without assigning to a different symbol to prevent
# shadowing previous loads and trigger a buildifier warning.
tf_workspace3 = workspace