Hi ! Is there an existing library/repository for (...
# multiplatform
l
Hi ! Is there an existing library/repository for (un)compressing a folder in/from a zip archive in KMP (I'm targeting Compose MultiPlatform) ?
1
If not, what would you advice me as implementations for Android/Windows/Linux ?
w
First of all, KmpIO seems like it might be what you seek. Second, Windows/Linux isn't necessarily a target platform. So I'll assume that you want an Android app and a Desktop app. Based on this assumption, you only need to implement it in JVM. Then it should work in both Android and Desktop. Even if you want to write it yourself, it's quite trivial because you only need JVM, you can google for Kotlin or Java solutions for this, or simply even ask an LLM if that's your style.
l
Thank you very much. So I'll use it 🙂
Indeed I've also asked a LLM for a code and it gave a code around the JVM features. But your solution handles the coroutine and may be more optimized and less error-prone 🙂
👍 1
Oups: I did not notice at first that KmpIO is not targeting desktop. So I'll need to implement a version with the JVM features. My main concern is still to handle exceptions as I am still new to coroutines : I'll still investigate into that.
w
KmpIO targets JVM, so it should be available on Desktop
l
I was just afraid because of this (list is maybe not exhausted ?)
Copy code
Supported targets:

Android X64 and Arm64 ABIs
macosX64
macosArm64
iosX64
iosArm64
iosSimulatorArm64
🤔 1
w
But since you have only Desktop and Android, you should have access to
java.util.zip.ZipFile
in your common code (because of the commonizer)
👍 1
l
Ok, that fine so. Thank you very much 🙂