Skip to content

Fix buildifier setup#217

Open
nettle wants to merge 1 commit intoEricsson:mainfrom
nettle:bazel-buildifier
Open

Fix buildifier setup#217
nettle wants to merge 1 commit intoEricsson:mainfrom
nettle:bazel-buildifier

Conversation

@nettle
Copy link
Copy Markdown
Collaborator

@nettle nettle commented Apr 7, 2026

Why:
Buildifier setup is a bit excessive.
It can be improved.

What:

  • Remove duplicating aspect_rules_lint
  • Uplift buildifier version
  • Silence warnings from compiler

Addresses: #155

@nettle nettle force-pushed the bazel-buildifier branch from 2e482d1 to d46ff4a Compare April 7, 2026 17:28
@nettle nettle requested review from Szelethus and furtib and removed request for furtib April 7, 2026 19:06
Copy link
Copy Markdown
Contributor

@furtib furtib left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that I did rush the buildifier patch a bit, and we would benefit from clearing it up.

However, I have some concerns about this change, see my comments.

Comment thread BUILD
Comment thread MODULE.bazel
bazel_dep(
name = "buildifier_prebuilt",
version = "6.4.0",
version = "7.3.1",
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct me if I'm wrong, but Buildifier versions are matching their Bazel "counterpart".

This is why I choose 6.4 to match the lowest version we still support.

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I see. I'm actually not sure there are matching, but you might be right

Comment thread BUILD
Copy link
Copy Markdown
Contributor

@furtib furtib left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please also remove:

http_archive(
name = "aspect_rules_lint",
sha256 = "329cf5ba776a75b70049a5695e9ca29a25113230f4f447aff7102b62afe7c24a",
strip_prefix = "rules_lint-1.11.0",
url = "https://github.com/aspect-build/rules_lint/releases/download/v1.11.0/rules_lint-v1.11.0.tar.gz",
)
http_archive(
name = "bazel_lib",
sha256 = "0758ace949a93f709230a8e08ef35c5f0aacae2ff5d219b27da1d21d8233a709",
strip_prefix = "bazel-lib-3.0.0-rc.0",
url = "https://github.com/bazel-contrib/bazel-lib/releases/download/v3.0.0-rc.0/bazel-lib-v3.0.0-rc.0.tar.gz",
)
load("@bazel_lib//lib:repositories.bzl", "bazel_lib_dependencies")
bazel_lib_dependencies()
load(
"@aspect_rules_lint//format:repositories.bzl",
# Fetch additional formatter binaries you need:
"rules_lint_dependencies",
)
rules_lint_dependencies()

Otherwise LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants