gpt4 book ai didi

android - 不使用 Playstore 的多台设备上的远程更新应用程序

转载 作者:太空狗 更新时间:2023-10-29 16:42:44 25 4
gpt4 key购买 nike

我正在尝试找到一种解决方案,将 APK 远程更新到 80 台平板电脑。这应该尽可能自动化,如果这可以完全在后台发生而无需任何用户输入,那就太好了。基本上,Playstore 目前的功能我无法使用。

如果不对设备进行 root 操作,这样的事情是否可行?关于这样做的图书馆/服务有什么建议吗?

我运行的是 Android 4.1.1,它们都将连接到 Wi-Fi。

最佳答案

你可以下载新的APK文件到SD卡,然后调用这个安装:

Intent shareIntent = new Intent(Intent.ACTION_VIEW);
shareIntent.setDataAndType(Uri.fromFile(new File("path-to-APK-file")),
"application/vnd.android.package-archive");

try {
context.startActivity(shareIntent);
} catch (Throwable t) {
// handle the exception here
}

只有一件事不是自动的:最后一步。系统会要求用户确认安装。

关于 APK 文件的 MIME 类型,这里是 wiki page .

关于android - 不使用 Playstore 的多台设备上的远程更新应用程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/15099584/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com