Replies: 1 comment
-
Unfortunately not, there is no mechanism to invoke actions as part of a call to clean. Clean only clears the artifacts that bazel knows about. However a hanky workaround would be to provide a custom tools/bazel script that intercepts bazel clean and does your custom cleanup operations then. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
Am wondering if I have a build with a "make" rule and someone runs "bazel clean" is it somehow registered to run the underlying "make clean" to cleanup any intermediate files that aren't necessarily registered with bazel as output files?
I ask because I have a use case where I have blackbox sub-build that I'm invoking from a custom rule. I'm trying to set it up so that we call the sub-build's "clean" upon "bazel clean". The sub-build owns the location of intermediate files (they don't live in any directory that bazel is aware of and thus don't get cleaned). Thought I'd check to see if you had found a solution for this.
Thanks,
Rob
Beta Was this translation helpful? Give feedback.
All reactions