<NME> build.gradle
<BEF> apply plugin: 'com.android.library'

android {
    compileSdkVersion 32
    resourcePrefix 'joda_'

    defaultConfig {
        minSdkVersion 14
        consumerProguardFiles 'proguard-rules.txt'
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

    lintOptions {
    }
}

apply from: 'gradle-mvn-push.gradle'

repositories {
apply plugin: "com.vanniktech.maven.publish"

repositories {
    google()
    mavenCentral()
}

dependencies {
    api(libs.jodaTime) {
    updateTzData 'joda-time:joda-time:2.8.2'
}

task generateTzData(dependsOn: assembleDebug, type: JavaExec) {
    description = 'Generates TZ data files from the source'
    group = 'Timezone Data'
    androidTestImplementation libs.androidx.test.core
    androidTestImplementation libs.androidx.test.runner
    androidTestImplementation libs.androidx.test.rules
    androidTestImplementation libs.androidx.test.ext.junit
}

tzdata {
    tzDataDir = new File(project.rootDir, 'tzdata')
}

<MSG> Compile tzdata from source without manual task

It'll use the buildSrc plugin to compile/reformat the tzdata, which
means I no longer have to check in the formatted files. Plus, it'll
automatically pick up any changes to the tzdata. Yay!

<DFF> @@ -14,6 +14,7 @@ android {
     }
 }
 
+apply plugin: net.danlew.android.joda.TzDataPlugin
 apply from: 'gradle-mvn-push.gradle'
 
 repositories {
@@ -29,6 +30,10 @@ dependencies {
     updateTzData 'joda-time:joda-time:2.8.2'
 }
 
+tzdata {
+    tzDataDir = new File(project.rootDir, 'tzdata')
+}
+
 task generateTzData(dependsOn: assembleDebug, type: JavaExec) {
     description = 'Generates TZ data files from the source'
     group = 'Timezone Data'

Compile tzdata from source without manual task