https://pantsbuild.org/ logo
#general
Title
# general
b

bumpy-spoon-55438

08/13/2022, 9:26 PM
Hi, I am writing a custom plugin which a command is invoked in a Process and multiple documents are generated. the problem is I don't know what files and directories will be created beforehand so how to construct the output files for the Process?
h

happy-kitchen-89482

08/13/2022, 9:26 PM
Can you control which subdirectory of the sandbox they get written under? You can capture an entire output directory
b

bumpy-spoon-55438

08/13/2022, 9:32 PM
yes. I know which subdirectory they get written into
so how to capture en entire output directory?
e

enough-analyst-54434

08/13/2022, 9:56 PM
Hopefully you've found this section of the docs, but just missed this bit: https://www.pantsbuild.org/docs/rules-api-process#output-files
So you can use
output_directories
instead of
output_files
.
b

bumpy-spoon-55438

08/13/2022, 11:29 PM
got it. I missed that part. thanks for pointing out
3 Views