Google created the functionality called PAI (Play AUto Install) on Android that automatically downloads apks from Play Store after factory reset if connected to network. What exactly trigger this functionality in android code. (I assume that the stub and the device config apk are correctly installed in the image).
What exactly trigger this functionality in android code?
-> The presence of the PlayAutoInstallConfig.apk with APKversion:=1 in /system/app/PlayAutoInstallConfig/ on the device.
Related
I built an app for a client, but it must be private so I can't publish it in the store.
This application is installed in 30 devices, so every time I release some updates another guy has to install the new app in every device. I was wondering if I could update the app from a link or something.
My idea is to insert in a table the current version with the link of the app that expo provides me after the build.
Once I press the button "check for updates" I check the version installed and if it's old, I will download the app from the link and install it automatically.
Is it possible at least for Android? For ios I don't care so much since it is installed only in one device.
I read about updates from expo wiki but I think it works only for published apps
thanks
Put the .apk on a server in the internet.
Everytime your app starts it starts a thread that checks if the .apk on the internet is different/newer from the one that is running.
If so then the new one is downloaded automatically.
When all done your app starts an install intent at a suitable moment.
Google Play can distribute private app to devices registered in your organization.
You can read this for more info: https://support.google.com/googleplay/android-developer/answer/6145139?hl=en
I would like to know if there is any effective way to test an app for Huawei Store using an Android Studio emulator.
I tried disabling the Google Play Services, but for some reason Retrofit requests stopped working :/
You can use Cloud Debugging of AppGallery Connect to test your app for Huawei Devices.
Cloud Debugging tests your app using mainstream Huawei devices provided by Huawei. You can run your app on the latest and most popular Huawei devices to test app functions.
Work with Cloud Debugging
Sign in to AppGallery Connect and select My projects.
Select an app to be tested.
Go to Quality > Cloud Debugging.
Filter devices by Series, Android version, EMUI version, and Resolution.
In the Apply for device model dialog box that is displayed, set Debug duration based on your needs. The options are 30 min, 1 h, and 2 h.
Wait for the device initialization to finish.
Click the Debugging tab.
Click Upload to upload an APK.
Check the APK upload progress and install the APK after the upload is complete.
In the displayed dialog box indicating that the app is being installed, click OK. When the installation is complete, you can see the app icon on the device screen on the left.
Operate the device by moving or clicking your cursor on the device screen, or clicking the power button, home button, menu button, or back button. The device will respond like your own phone.
Check Screenshot below:
You can check out the official documentation for a more complete answer.
For most cases, you can simply grab HMS Core APK and install it on emulator or physical device
You do not need for most cases Huawei device. Here is my battle-tested solution.
If you're implementing HMS (Huawei Mobile Services) feature like push notifications, sms retrieving or auth(orization) you can do simply:
Grab HMS Core APK from: https://www.huaweicentral.com/download-the-latest-huawei-mobile-services-apk/
Create new or run existing Android emulator via Android Studio or ADB
Install HMS Core APK downloaded from 1.
Go to Settings -> Apps & Notifications
Make sure that HMS Core has required permissions like SMS for SMS retrieving or push notifications
If you forget about 5., HMS library will return exception "Permissions not enabled"
I am pretty sure that instead of emulator you can use any of physical devices, grab APK and install HMS Core on it.
From: https://stackoverflow.com/a/63790263/4730812
Happy coding!
Well, I was trying here to make Retrofit work in this condition and I found a way.
I don't know if it is the best solution, but I will post it anyway.
disable the Google Play Services;
force stop your app;
restart the emulator;
check if it is working now (if not, try to force stop your app again).
P.S.: Google Play Services is not re-enabled upon reboot.
I have followed the sample here: https://github.com/googlesamples/android-WearVerifyRemoteApp. I ran the app on Wear Emulator (Android 6.0.1). I reached the point where the app is not installed on phone and want to launch the app link on Google Play on the device:
// Create Remote Intent to open Play Store listing of app on remote device.
Intent intentAndroid =
new Intent(Intent.ACTION_VIEW)
.addCategory(Intent.CATEGORY_BROWSABLE)
.setData(Uri.parse(PLAY_STORE_APP_URI));
RemoteIntent.startRemoteActivity(
getApplicationContext(),
intentAndroid,
mResultReceiver);
I attached the debugger and, yes, I reached this line, but nothing happens. Google Play is not launched on the phone. I am sure I am connected to the phone as other notifications from the phone (real device) appears on the emulator.
Edit:
Not clear why but connection from the phone to the emulator is really buggy. It's really frustrating and the issue was solved but disconnecting and reconnecting many times.
AFAIK, you need to have a phone APK and a watch APK in your Android Wear app then you must use the Multi-APK delivery method. which is, as mentioned,
Multiple APK support is a feature on Google Play that allows you to publish different APKs for your application that are each targeted to different device configurations.
If you haven't done so, try enabling Advanced mode in your application's APK files tab to be able to publish multiple APKs for your app.
For more information, see Packaging and Distributing Wear Apps.
I have an app installed(created by me) on my android phone. How will I code the functionality to automatically update from Playstore, without notifying the user(since I have trusted the old app instalation).
You can update your Android device's apps individually or allow them to be updated automatically:
Open the Google Play Store app Play Store.
Tap Menu Menu and then Settings.
Tap Auto-update apps.
Set up automatic updates
To set up automatic updates for all apps on your mobile device:
Open the Google Play Store app Play Store.
Tap Manu - > Settings.
Tap Auto-update apps.
Select an option:
Auto update apps at any time: Updates apps at any time, using either
Wi-Fi or mobile data.
Auto-update apps over Wi-Fi only: Updates only when you are connected to Wi-Fi.
Note: If an account on your device has a sign-in error, apps may not update automatically.
You can google it also same processor written everywhere.
#ratheesh
Inside your SplashActivity only if you want to force update
final String appPackageName = getPackageName();
startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appPackageName)));
The method for turning on and off automatic app update on Android devices has changed several times over the years. For example, see How to Disable Automatic App Updates in Android. And for example, current Google Play Help advice is not applicable for users running the latest Android and Google Play Store software versions.
I am running Android Version 10 with One UI Core 2.5 and Google Play Store Version 25.5.22-21 on a recently-acquired Galaxy A12 phone.
On my phone, after opening the Google Play Store app, I click on my round Google profile icon (in the orange square in the image below) in the upper right corner of the Play Store app window,
click on Settings (in the red oval in the image below),
and select 'Auto-update apps' in the Settings window.
An implication is that changing the auto-update setting is now going to affect all Android devices being managed via that Google profile.
I hope this helps others trudging along in my footsteps.
I am currently investigating ways of remotely updating an Android app installed on a number of devices. The app in question is to be used on phones which we will provide to a number of demonstrators as part of product presentations. For this reason we don't want to publish the app on Google Play to be available for the public at large.
I've read that you can restrict access to the device on Google Play, but only according to criteria such as location, device type, android version, etc. Another way is to set up a version for beta testing, for which you can select testers, however this is only available to those who are part of a Google group or a Google+ community (according to here).
I've come across another post which details how to install an apk programmatically, however it appears to install the apk automatically, ie it doesn't appear to check whether or not the update is actually a new version.
One idea I have in mind is to upload new version on a repository and broadcast to devices which have the app installed, of which we have stored device ids. Is this possible?
What we do is sync periodically to a remote server during data entry on the app. During this sync, we check to see whether the device has the latest version of the software. If it doesn't, the new apk is downloaded and the user is prompted to install the software.
This is accomplished using a separate installer app we created. We have a service that keeps the app alive in the background, so it looks like the user never actually leaves the app during the install.
Would be happy to post code on the installer.
You can see the self installer here: https://github.com/techartist/SelfInstall-Jelly-Bean/
You should try Beta by Crashlytics, it's email-based.
You should try beta or alfa testing in gplay.
Also you can hardcode the date of ending and not to open application after this date.