workspace: Adding bazel build formatter/linter
Adds in buildifier bazel targets that autoformat/lint the entire
WORKSPACE. This can be invoked by running;
'bazel run //:buildifier'
or
'bazel run //:buildifier_test'
Change-Id: Iaaf7f6241e29894eca94aa6b5d0ca3b33255b7f7
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/36160
Reviewed-by: Keir Mierle <keir@google.com>
Commit-Queue: Keir Mierle <keir@google.com>
diff --git a/pw_thread_threadx/BUILD b/pw_thread_threadx/BUILD
index 427af06..a333d23 100644
--- a/pw_thread_threadx/BUILD
+++ b/pw_thread_threadx/BUILD
@@ -43,16 +43,16 @@
"//pw_thread:id_facade",
],
# TODO(pwbug/317): This should depend on ThreadX but our third parties
- # currently do not have Bazel support.
+ # currently do not have Bazel support.
)
# This target provides the ThreadX specific headers needs for thread creation.
pw_cc_library(
name = "thread_headers",
hdrs = [
+ "public/pw_thread_threadx/config.h",
"public/pw_thread_threadx/context.h",
"public/pw_thread_threadx/options.h",
- "public/pw_thread_threadx/config.h",
"public/pw_thread_threadx/thread_inline.h",
"public/pw_thread_threadx/thread_native.h",
"public_overrides/pw_thread_backend/thread_inline.h",
@@ -63,8 +63,8 @@
"public_overrides",
],
deps = [
- "//pw_assert",
":id",
+ "//pw_assert",
"//pw_thread:thread_headers",
],
# TODO(pwbug/317): This should depend on ThreadX but our third parties
@@ -77,9 +77,9 @@
"thread.cc",
],
deps = [
- "//pw_assert",
":id",
":thread_headers",
+ "//pw_assert",
],
# TODO(pwbug/317): This should depend on ThreadX but our third parties
# currently do not have Bazel support.
@@ -87,23 +87,23 @@
pw_cc_library(
name = "test_threads",
- deps = [
- "//pw_thread:thread_facade",
- "//pw_thread:test_threads_header",
- "//pw_chrono:system_clock",
- "//pw_thread:sleep",
- ],
srcs = [
"test_threads.cc",
- ]
+ ],
+ deps = [
+ "//pw_chrono:system_clock",
+ "//pw_thread:sleep",
+ "//pw_thread:test_threads_header",
+ "//pw_thread:thread_facade",
+ ],
)
pw_cc_test(
name = "thread_backend_test",
deps = [
- "//pw_thread:thread_facade_test",
":test_threads",
- ]
+ "//pw_thread:thread_facade_test",
+ ],
)
pw_cc_library(
@@ -128,13 +128,13 @@
],
deps = [
":sleep_headers",
- "//pw_chrono_threadx:system_clock_headers",
"//pw_assert",
"//pw_chrono:system_clock",
+ "//pw_chrono_threadx:system_clock_headers",
"//pw_thread:sleep_facade",
],
# TODO(pwbug/317): This should depend on ThreadX but our third parties
- # currently do not have Bazel support.
+ # currently do not have Bazel support.
)
pw_cc_library(
@@ -148,7 +148,7 @@
"public_overrides",
],
# TODO(pwbug/317): This should depend on ThreadX but our third parties
- # currently do not have Bazel support.
+ # currently do not have Bazel support.
)
pw_cc_library(