Is there an api to help download external tools in...
# plugin-development
c
Is there an api to help download external tools in Gradle? Say a native binary that I need Gradle to switch which os/arch it needs to download depending on OS building the app.
Bazel makes this trivial, but I've never found a simple way to do this.
Some projects use undercouch.download, but then you're dealing with manually creating the download url and handling os/arch yourself.
p
Well, it depends on the location of the tool
or any other download
p
You can always use the JVM properties to get the current os and arch. Another way would setting up a ivy repository, if you expect a (enterprise) user might block the location, and requires a mirror.
c
I guess I need something like how google handles protoc https://repo1.maven.org/maven2/com/google/protobuf/protoc/4.34.1/
p
Uploading it to a repository is the ideal solution, but having your own repository isn't always an option.
n