I am using a windows 10 OS. I had the jks file in desktop. Then i gave the path to the file and built a signed apk. It was fine. Then i moved the jks file to another location. When I tried to build a signed apk, I gave the new location in the dialogue window. But the build failed. The message said, jks file was not found in desktop. Why android studio is still looking for the file in desktop even after changing the location? Should I change the path in some other place too?
If I were in a similar situation I would invalidate cache and restart first, then when building signed apk I would give keystore path again by clicking "Choose existing..." and proceed.
Related
I'm trying to publish a xamarin.android app. I'm using Visual Studio with Xamarin Android 6, so I followed this. In part 2, it describes how to create a new keystore as shown in the following screenshot (You can see the complete describtion here):
I don't get where should I place this command. I looked at that keytool link, but couldn't find any thing. I tried cmd, MSBuild Command Prompt for VS2015 and Developer Command Prompt for VS2015, but all of them showed this error: '$' is not recognized as an internal or external command, operable program or batch file.
In addition to, I tried to create a new keystore using Visual Studio. I went to tools>Android>Publish Android App and I created a keystore and it appeared in path that I specified. Then I went back to that guide and continued from Sign the APK. But there's not any .apk with name and path that I specified. There are just 3 .apk that were before doing all this and don't work.
Now my question is that where should I use that command? In furthermore, I would like to know is there any other way to publish an xamarin.android app?
Reyhaneh,
Keytool is an executable provided by the Java SDK. You'll find it in your Java SDK folder, for example:
C:\Program Files (x86)\Java\jdk1.7.0_55\bin\keytool.exe
You can execute it in a normal command prompt. To create a new keystore, open a command prompt with the following line:
"C:\Program Files (x86)\Java\jdk1.7.0_55\bin\keytool.exe" -genkeypair -v -keystore <filename>.keystore -alias <key-name> -keyalg RSA -keysize 2048 -validity 10000
From my experience in generating the KeyStore and eventually publishing to google, which worked like a charm.
You first have to Archive your Xamarin.Android project by clicking on the Build menu and clicking Archive. If all works fine, this should archive the project but that's not our target. (Also please make sure the App is set to APK in the Android Package Format in the Project Properties. Just in case)
When it's complete, click on it and click the Distribute button at the bottom of the archive page.
Choose Adhoc
Click the Plus button to create the KeyStore
Fill out the form
Now, click SaveAs
Choose any place to put the APK file (we don't really care at this point)
Wait for all to be done
Go C:\Users"YOUR PC USER NAME"\AppData\Local\Xamarin\Mono for Android
You will see the KeyStore folder. Go into it to see your App folder containing your KeyStore. Please copy the entire folder and perhaps put it in your App source code folder for safekeeping or any other location of your choice.
THAT'S IT
FOR GOOGLE PLAY STORE PUBLISHING
You will need to provide the KeyStore in the Android Package Signing page in the project properties for the Android project. This is very essential as it's required before your app can be uploaded to the play store.
Next, change the Android Package Format in the Android Options tab (in the same android project properties windows) to Bundle
Now achieve the android project again by clicking the Archive button in the Build menu. This will now create the App Bundle file for Google Play Store. You can click on the Open Folder when done to get your app bundle file.
GREAT!!1
THAT IT...
Hope this helps... It's a pain at times to do all this just to get your app ready for publishing on the plat store or for other reasons.
You may get some additional information from the link below. It may be helpful as it contains some screenshots but it's not as simplified as what I have done above.
https://learn.microsoft.com/en-us/xamarin/android/deploy-test/release-prep/?tabs=windows
I have built an application using Eclipse IDE and then when I try to "Export Signed application" - I fill out the forms and create keys and other things that I'm supposed to do. But I cannot find the APK file at the destination I specify. I know that there's an APK file under bin but it's not zipaligned.
Same thing with Zipalign when I specify the output file, I cannot see the output file although it says "Verification successful". I have tried running Eclipse under Administrator mode but doesn't matter. Thanks!
I am trying to use calabash tool for automation of android application, while signing application I got following error:
jarsigner error: java.lang.RuntimeException: keystore load:
C:\Users\pcadmin.INFPU08742\.keystore (The system cannot find the file specified)
I have debug.keystore file in ./android folder
Please let me know what is required?
How are you signing the apk? If it's through the terminal it can become quite a huge mess. At least that happened to me. A quick solution is simply to get the signed apk from eclipse -> right click on Application package(in package explorer) -> Android tools -> Export Signed apk. Just specify the keystore location and use android as password. That should do the trick.
I am trying to Sign up APK to upload it on to the Play Store Market. I am following the steps underlined here
I am getting the following error
When i try to Sign the Application using Eclipse project->Android Tools->Export Signed Application Package.
You don't need to do it with commands. In Eclipse, right click on your project->Android Tools->Export Signed Application Package.
Follow the wizard and you will have an signed apk without pain.
Edit:
After a quick search about the new error, this thread seems to contain possible fix for you. At instance, please try to clean your project and build it again. If it does not fix your problem, also try the fix mentioned in the link.
Copy your keystore file to a directory which has no spaces. Your current path is C:\Program Files (x86)\Java\jdk1.6.0_27\bin\my-release-key.keystore which contains the directory Program Files (x86) with spaces. JarSigner cannot identify directories with spaces.
I am developing gps base app. For that i need the md5 so i have tried to open the file debug.keystore using notepad,so file format is change to notepad, now i have got the google-apiKey using key-tool menu (install plug-in keytool ), but problem is that when run my app it give me the following error
Error generating final archive: java.io.IOException: Invalid keystore format Unknown Android Packaging Problem
I am not even sure where to begin to look. I cannot launch the application. Can someone give me an idea on what area I can look into?
A
I am solve this problem
Delete your debug certificate under ~/.android/debug.keystore on Linux and Mac OS X; the directory is something like %USERPROFILE%/.androidon Windows.
The Eclipse plug-in should then generate a new certificate when you next try to build a debug package. You may need to clean and then build to generate the certificate.
Your debug keystore was created automatically