Could not download builder.jar (com.android.tools.build:builder:3.2.0): No cached version available for offline mode - jar

enter image description here
Could not download builder.jar (com.android.tools.build:builder:3.2.0): No cached version available for offline mode

Disable the offline mode by visiting File-> Settings -> Build, Execution, Deployment->Gradle and uncheck Offline work
Make Sure that you are connected to the Internet
Go to Build-> Make Project (Ctrl+F9) and let the gradle download the essential files
Rebuild the project

Related

xamarin.forms Android release build only works with fast deployment enabled

For the past days I had major issues with deploying the android version of my app. I found out that I am only ever able to get the app to work when "Fast Deployment" is checked. However, this means I can never archieve my app. If fast deploy is enabled, the app, even though it is in release mode, is treated like a DEBUG build and therefore not accepted in the playstore.
If i uncheck fast deploy for release builds the app starts and then idles, not doing the first rest call it is supposed to do. If I leave the rest calls out, the app again works.
How can this be correlated?
The symptom that it works when set "Fast Deployment" suggests this situation:
If you are testing a release build on a device that previously had a debug build, its possible that the debug version did not get fully uninstalled. Specifically, "Fast Deployment" stores the xamarin library as a separate DLL. Because your release build has the same "bundle id" as the debug build, Android can get confused.
To fix.
Best Fix for emulator:
Tools / Android Device Manager / Select virtual device / Edit / Clear to Factory Defaults.
Quickest fix for phone (but not sure if it helps):
Drag app to trash can.
Power down the phone. Power it back on.
Deploy release build to device. Either by installing apk, or by "Start Without Debugging" menu item.
Quick Fix:
Run debug version again on the device. This makes sure Android "knows" that the debug version of app is there.
Stop the app.
On the device, "uninstall" the app. (Drag it to trash can).
Deploy release build to device. Either by installing apk, or by "Start Without Debugging" menu item.
If that doesn't work, then use "adb uninstall":
Run debug version again on the device. This makes sure Android "knows" that the debug version of app is there.
Stop the app.
menu Tools / Android / Android Adb Command Prompt.
adb uninstall com.companyname.appname <-- substitute your app's bundle id
deploy release build to device.
It turnes out that turning ON my linker to link assemblies only actually decreased the app size AND made everything work again. Before, the linker was set to LINK NONE (which should've been the safer bet, but turned out to be an error...).

Enterprise build for apple watch

I am trying to create enterprise build for apple watch project by xcode 6.3
I tried to build by archive and by auto-build (shenzhen tool)
When I run it at iPhone, it crashes immediately but with ad-hoc build it's work fine.
I've found that Xcode Automatic selections do not work properly for code signing and provisioning profile when used with Apple Watch; sometimes it makes the wrong choice and you only notice when it has problems installing and launching.
For each of the App, App Extension, and Watch App, select the code signing certificate and provisioning profile explicitly (not automatic) in the pop up list.
For issues upon launch on the device (from spring board) the device console gives good information. Install iOS Console, from lemonjar.com to easily see such information.

How to implement a "quit to upgrade and restart" installer?

Many applications have this functionality now, but a good example is the Spotify client.
The app discovers there is a new version available, downloads it in the background then prompts the user to restart to get the new version. When the user quits the new version is installed (or the installed version is patched) then the application is restarted, all without further user interaction. In fact, the user really doesn't even have to do anything the app would automatically update on every exit if the user was never notified.
We have a cross-platform Qt 5.3 application and our lean startup business model requires us to push application updates very often so I'd really like to find a method that works cross platform with as little platform specific code as possible.
There are multiple parts to this question.
Noticing the update, and downloading the installer. (Obvious, and not a problem)
Running the installer application. Not an issue except how does one gain privilege? Spotify never asks for privilage to install again after the first install.
Avoiding "This application has been downloaded from the Internet" approval dialogue on every update.
Restarting the application after upgrading, but only when the user responded to the quit and upgrade prompt.
Specifically are there any tools, installers or code examples that do this?
You can follow how Google Chrome and Opera (latest one, not version <= 12) do it, rougly as below:
When installing the application, create a scheduled task that runs an updater as administrator (or a user with permission to write files to your application directory) periodically. For example in Windows, you can find GoogleUpdateTaskMachineCore and GoogleUpdateTaskMachineUA entries in Task Scheduler.
Your application structure looks something like the following (Google Chrome has similar structure in C:\Program Files (x86)\Google\Chrome\Application):
C:\Program Files\AwesomeApp\launcher.exe
C:\Program Files\AwesomeApp\1.0\AwesomeApp.exe ; version 1.0 of application
C:\Program Files\AwesomeApp\1.2\AwesomeApp.exe ; version 1.2 of application
The application shortcut created by installer will run launcher.exe. This launcher.exe will run the latest version of AwesomeApp.exe available in the directory. For example in the above structure, launcher.exe will run AwesomeApp\1.2\AwesomeApp.exe.
When the updater finds an update, it will download it and add the new version to the directory in the background. After that it will tell the running application (if it is running) to notify the user that an update is ready and can be used by restarting the application. And of course your older application needs to close itself and restart by running launcher.exe too. This updater may delete old application versions and keep only the latest two versions.

Xcode Application Loader

I am a novice when it comes to apps but i have managed to write one, test it, debug it, install it onto my Iphone. I'm now on the final step upload it through application loader...
my problem is i can't get application loader to install. i have downloaded it, run the .dmg, this creates a new device on my system with the file applicationloader.pkg. I run this and it runs me through the installation, i have entered my admin authority, it says installation complete.
But it doesn't have the program anywhere. i have looked in Applications, searched in the finder and i can not locate where the application loader is.
1 - is there a reason why it wouldn't be installing properly?
2 - is there a way to download a previous version (current is 2.7) to try that
3 - is there a way of uploading without the application loader?
If you have the latest Xcode installed on your machine, go to the Xcode menu item/Developer Tools and open the Application Loader. If you are working with Xcode there is no need to use the application loader though. Every step you need to bring your app into iTunes connect can be done via Xcode. The steps are Archive (for Release), select the archive - validate it (you mast have prepared your app in iTunes Connect (must be in the status ready for upload) and the submit it to the store.

Xcode 4 Ad-Hoc Distribution - Unable to Download

I had recently upgrade our development machine to Xcode4 and after the initial interface change has gone quite smoothly.
I'm now in the process of using Ad-Hoc distribution on it for the first time so I followed this guide to set up profiles/schemes etc. http://diaryofacodemonkey.ruprect.com/2011/03/18/ad-hoc-app-distribution-with-xcode-4/
This is the process I took:
1/ Setup a new provisioning profile under distribution. I selected Ad-Hoc, the correct App and my UUIDs.
2/ Installed the profile within Xcode 4.
3/ In xcode duplicated the Release Configuration and named it Ad-Hoc.
4/ Under Code-Signing made sure Ad-Hoc had the new profile selected.
5/ Edit Archive scheme and selected 'Ad-Hoc' Build Configuration.
6/ Select Product > Archive and made sure the profile listed was correct.
7/ On save screen selected 'enterprise distribution' and entered the App URL and Title.
8/ Copied the resulting ipa archive, plist and mobileprovision (downloaded in point 1) to our http server.
9/ Added the required html to and pointed mobile Safari to it.
10/ Selected the mobileprovision which installed without a problem.
11/ Selected the App which begins to install resulting in "Unable to Download" at about 90%.
I've tried several potential solutions from other posts but they all result in the same thing. This is used to work fine in Xcode 3 (using normal developer account, NOT enterprise) and as far I can tell I'm not really doing anything different so what am I doing wrong?
Thanks.
Try this: Open the Scheme you are using to edit it. Then check if in ALL the build phases (Build, Run, Test, Profile, ...) the Build Configuration is set correctly. If not set it to the correct configuration and build it again.
If this does not work ad a new Entitlements.plist to your project and add a new value with the key get-task-allow to NO.
Edit: Have you tried to make Product > Build For > Build For Archiving and then Product > Archive.
This worked for me.
we just had the same problem (and we still have it for one device only working on iOS5 Beta, not sure if it is related. All other devices work.), some tips that could help :
Apple dev site:
your provisioning profile could need to be renewed on the apple web site.
on the apple web site check that the device is linked to the provisional profile in the "Device" section. In the "provisional profile" section, the "Edit" feature could lie to you. To add a missing device to a provisional profile, go the "provisional profile" section then uncheck and check back the missing device (the lying part from apple web site ;))
in xcode:
I switched deployment target OS from 4.0 to 4.2
I plugged my iPhone and selected it as target before to create the archive.
this issue doesn't depend on the "team provisioning file", we could build a working archive with another provisioning file too.
If it can help too, I created a doc for distributing the Moodle app but it's generic to any app I guess: http://docs.moodle.org/dev/how_to_distribute_iPhone_test_app

Resources