I’m writing a gradle plugin that requires an external CLI. I have logic to check if the program exists in the path already, but when it isn’t found, I want to fetch the exe and unpack it somewhere that the plugin can use it. However, I have no idea where to put it.
When I put it in the projects temp directory ("{project.rootDir}/build") it works fine, but any time that directory gets cleaned, my plugin will download and unpack the CLI again, which I do not want. I would put it in the system temp directly like %TEMP% or %LOCALAPPDATA%, but windows blocks running executables in those directories.
Is there some place I should put a CLI that a gradle plugin will use other than another directory in the project root? I’d rather not inconvenience consumers of the plugin by making them add to their .gitignore (or other VCS equivalent)?