V0.17.0
Enhancements
We are excited to announce support for the Gradle Transform API in Okbuck. Okbuck now supports porting over gradle transform classes to be run during the buck build. You can configure it as follows
okBuck {
...
experimental {
transform = true
}
transform {
transforms = [
'another-app' : [
[
transform : "FULL_QUALIFIED_CLASS_NAME",
configFile: "CONFIG_FILE_PATH" // optional
]
],
]
}
}
dependencies {
transform TRANSFORM_DEPENDENCY
}
Okbuck transform CLI can create a transform in two ways.
- A class name with an empty constructor
- A class name with a
java.io.File
argument constructor
The file can contain anything in it. The transform can then read the file and parse it in whichever format it wants it in. The file is a way to pass in configuration that is traditionally done via gradle project/extensions.
Notes
- The android bootclasspath is already passed in the transform invocation as a referenced input jar.
- The transform step runs before the dex step. Applying a transform disables predexing, slowing down the build. So it is better to create a separate
buildType
and apply transforms on it so regular development can still be fast. - Huge shoutout to @malbano for working on this feature.