This repository was archived by the owner on May 11, 2025. It is now read-only.
File tree Expand file tree Collapse file tree
processing/buildSrc/src/main/groovy Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -186,7 +186,8 @@ class ImportAar implements Plugin<Project> {
186186class ExtractAarJarsTask extends org.gradle.api. DefaultTask {
187187 @TaskAction
188188 void extractJars () {
189- File outputDir = new File (project. buildDir, ' libs' )
189+ // File outputDir = new File(project.buildDir, 'libs')
190+ File outputDir = new File (System . getProperty(" user.dir" ), " build/libs" )
190191 outputDir. mkdirs()
191192
192193 // Configuration compileClasspath = project.configurations.getByName('implementation')
@@ -202,10 +203,11 @@ class ExtractAarJarsTask extends org.gradle.api.DefaultTask {
202203 ZipFile zipFile = new ZipFile (aarFile)
203204 zipFile. entries(). each { entry ->
204205 if (entry. name. endsWith(' .jar' )) {
205- println " Classes JAR found: ${ entry} "
206- String aarName = aarFile. name. replace(" .aar" , " " )
207-
208- File jarOutput = new File (outputDir, " ${ aarName} .jar" )
206+ println " Classes JAR found: ${ entry} "
207+ String aarName = aarFile. name. replace(" .aar" , " " )
208+ String jarName = " ${ aarName} .jar" . replaceFirst(/ -\d +(\.\d +)*(?=\. jar$)/ , ' ' )
209+
210+ File jarOutput = new File (outputDir, jarName)
209211 jarOutput. parentFile. mkdirs()
210212
211213 // Write the JAR file to the output directory
You can’t perform that action at this time.
0 commit comments