Closed antranvn closed 4 days ago
@antranvn
First, get an Uri
for an asset:
val uri = AssetFileProvider.getUriForAsset("path/to.apk")
AssetFileProvider
comes from ackpine-assets
artifact.
Then just create a session with this Uri
and launch it as usual (see docs page):
val session = packageInstaller.createSession(uri)
// Now do whatever you want, e.g.
val result = session.await()
@antranvn Do you have any other questions?
Closing due to inactivity.
How can we install apks from assets folder? Can you give an example code?