Files
picar/car/build.gradle
2020-05-03 16:10:40 +09:30

27 lines
550 B
Groovy

configurations {
python {
canBeResolved = true
canBeConsumed = false
}
}
dependencies {
python project(path: ':protobuf', configuration: 'python')
}
task copyPythonCode(type: Copy, dependsOn: configurations.python){
// Copy python protobuf code from proto project.
from zipTree(configurations.python.asPath)
into 'src'
}
task build(type: Exec, dependsOn: copyPythonCode) {
commandLine 'python3', 'setup.py', 'bdist_wheel'
}
task clean {
doLast {
delete 'dist'
delete 'build'
}
}