8000 Allow overriding CUSTOM_COMPILE_COMMAND (#472) · reiyw/rules_python@ed6cc8f · GitHub
[go: up one dir, main page]

Skip to content

Commit ed6cc8f

Browse files
authored
Allow overriding CUSTOM_COMPILE_COMMAND (bazel-contrib#472)
This way if users have bazel wrappers the error message can be correct
1 parent 53ba6cb commit ed6cc8f

File tree

1 file changed

+1
-1
lines ch BDC5 anged

1 file changed

+1
-1
lines changed

python/pip_install/pip_compile.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
# $(rootpath) in the workspace root gives ./requirements.in
5555
if update_target_pkg == ".":
5656
update_target_pkg = ""
57-
update_command = "bazel run //%s:%s" % (update_target_pkg, update_target_name)
57+
update_command = os.getenv("CUSTOM_COMPILE_COMMAND") or "bazel run //%s:%s" % (update_target_pkg, update_target_name)
5858

5959
os.environ["CUSTOM_COMPILE_COMMAND"] = update_command
6060

0 commit comments

Comments
 (0)
0