
godot.gradle.projectExt.checkToolAccessible.kt Maven / Gradle / Ivy
package godot.gradle.projectExt
import org.gradle.api.Project
import org.gradle.nativeplatform.platform.internal.DefaultNativePlatform
fun Project.checkToolAccessible(toolPath: String) = exec {
with(it) {
workingDir = projectDir
isIgnoreExitValue = true
if (DefaultNativePlatform.getCurrentOperatingSystem().isWindows) {
commandLine("cmd", "/c", toolPath, "--version")
} else {
commandLine(toolPath, "--version")
}
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy