Is there a way to see the resulting BUILD file aft...
# general
c
Is there a way to see the resulting BUILD file after applying macros?
I suppose
./pants peek
will do most of the job.
h
You'll get some representation of it, yes. But other than that, there is no way to see the intermediate BUILD file afaicr.
🙏🏽 1
b
FWIW there is no "intermediate build file". Build files are evaluated as Python, so the closest thing would be taking the result of the
exec
and formatting the data
c
The macros doesn’t change the code of the BUILD file. So if you just cat the files after each other (macros first) you see what pants sees. Pants peek is the tool to use to inspect the result of parsing that, yes 👍
c
Thanks! For my most important use (viewing the dockerfiles produced from the inline instructions that are heavily parameterized), I did some "pants peek | jq" magic to extract only those.