Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use a common constant for detecting bzlmod being enabled #1295

Closed
rickeylev opened this issue Jul 5, 2023 · 0 comments · Fixed by #1302
Closed

Use a common constant for detecting bzlmod being enabled #1295

rickeylev opened this issue Jul 5, 2023 · 0 comments · Fixed by #1302
Labels
cleanup Tech debt, resolving it improves our own velocity help wanted

Comments

@rickeylev
Copy link
Collaborator

Various parts of the codebase detect whether bzlmod is enabled or not. Most of them copy/paste the same if @ in Label(..) trick, and use a comment to explain what they're doing.

Rather that copy/paste that everywhere, lets just have a constant defined that does this once, then code can simply check if BZLMOD_ENABLED.

PR #1287 is adding such a constant; this issue is for cleaning up the code to use it everywhere.

@rickeylev rickeylev added help wanted cleanup Tech debt, resolving it improves our own velocity labels Jul 5, 2023
github-merge-queue bot pushed a commit that referenced this issue Jul 10, 2023
#1302)

Various parts of the codebase detect whether bzlmod is enabled or not.
Most of them copy/paste the same if @ in Label(..) trick and use a
comment to explain what they're doing.

Rather than copy/paste that everywhere, this commit uses a constant
defined that does this once and reuses the constant value to determine
if bzlmod is enabled.

Closes: #1295
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup Tech debt, resolving it improves our own velocity help wanted
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant