From 952a85414b815afdae652f9951cbb04d4a73c8d3 Mon Sep 17 00:00:00 2001 From: Alexander Udalov Date: Tue, 7 Jun 2016 18:56:00 +0300 Subject: [PATCH] Rename packages in protobuf-java binaries and sources #KT-12581 In Progress --- .../infrastructure/build-protobuf-lite.kts | 5 +- update_dependencies.xml | 99 ++++++++++++------- 2 files changed, 66 insertions(+), 38 deletions(-) diff --git a/generators/infrastructure/build-protobuf-lite.kts b/generators/infrastructure/build-protobuf-lite.kts index 200d3bdfc6f..15e753884e0 100644 --- a/generators/infrastructure/build-protobuf-lite.kts +++ b/generators/infrastructure/build-protobuf-lite.kts @@ -71,9 +71,10 @@ fun main(args: Array) { assert(liteProfileReached && keepClasses.isNotEmpty()) { "Wrong pom.xml or the format has changed, check its contents at $POM_PATH" } - ZipOutputStream(BufferedOutputStream(FileOutputStream(File(outputPath)))).use { output -> + val outputFile = File(outputPath).apply { delete() } + ZipOutputStream(BufferedOutputStream(FileOutputStream(outputFile))).use { output -> for ((name, value) in allFiles) { - val className = name.substringAfter("com/google/protobuf/").substringBeforeLast(".class") + val className = name.substringAfter("org/jetbrains/kotlin/protobuf/").substringBeforeLast(".class") if (keepClasses.any { className == it || className.startsWith(it + "$") }) { val (entry, bytes) = value output.putNextEntry(entry) diff --git a/update_dependencies.xml b/update_dependencies.xml index c6ea0460b4d..8036d5d0ae3 100644 --- a/update_dependencies.xml +++ b/update_dependencies.xml @@ -197,6 +197,9 @@ + + + @@ -236,15 +239,11 @@ - - - - @@ -328,17 +327,6 @@ - - - - - - - - - - - - - + - - + + + - - - - - - - + + + + + + + + + + + - - - - - + + + - + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -683,8 +712,6 @@ - -