when i try to update my alpha release i receive the error that i need to change my apk version. But how can i do that? my android manifest:
<android xmlns:android="http://schemas.android.com/apk/res/android" android:versionName="1.1">
<manifest>
<uses-sdk android:minSdkVersion="14" android:targetSdkVersion="23"/>
<application>
<activity android:configChanges="keyboardHidden"
android:name="org.appcelerator.titanium.TiActivity" android:screenOrientation="portrait"/>
<activity android:configChanges="keyboardHidden" android:name="ti.modules.titanium.ui.TiTabActivity"/>
</application>
</manifest>
</android>
Ah, you talk about APK version, not about Android SDK. The solution is simple. You need to change the version at a couple places.
Change the version tag with at least the 3rd number (patch) increased
<version>1.0</version>
Can become
<version>1.0.1</version> or <version>1.1</version>
Next, you also need to change the part in the android manifest
<manifest android:versionCode="1"
android:versionName="1.0.1" package="com.example.app"
xmlns:android="http://schemas.android.com/apk/res/android">
Increase version code every time, can be same as version, in my example 101 for example. Or just a build number (1, 2, 3, etc)
Versionname should be the same as the version in the version tag. Also don't forget to put your app ID in the same code ;)
In TiApp.xml add version code and version name to manifest
<manifest android:versionCode="1" android:versionName="1.0">
Google is mainly complaining about version code so check that and increase by one. These settings will override the version of the app specified in the tag for android
Each APK you submit to Google Play must have a unique, incremental build version, which on Android is android:versionCode.
Titanium will use the <version> tag in tiapp.xml to set the release version which on Android is android:versionName.
To set the build version you need to add/use a <manifest> element under the <android> element in tiapp.xml like this:
<android>
<manifest android:versionCode="1">
..
</manifest>
</android>
The 4.1.0 Sample included a Gruntfile.js to easily increment the iOS and Android build versions. It can even bump the major, minor or patch release version for you.
Please read the blog post on versioning your apps with Titanium 4.1.0 and later for more information.
you also have to increment
<version>1.1</version>
Related
of course there are a lot similar questions and I really read through, but none of them completely answered my question:
I want to update my current app (already prod) on Google Play, but it says I need to change the versionCode -> 1 does already exist.
But I changed or added this in the AndroidManifest.xml, also the versionName.
You must know, I didn't add any versionCode or versionName in my first upload, could this cause the problem?
Do I have to delete the app now and re-upload it?
I surely used the same keystore and credentials
Steps done:
updated the AndroidManifest.xml
android:versionCode="2"
android:versionName="1.0">
created a new signed apk
tried to upload
Another question:
Do I really need to use the same apk-filename?
xml manifest:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.ibma.ibmaapp"
android:versionCode="2"
android:versionName="1.0">
<uses-sdk
android:minSdkVersion="19"
android:targetSdkVersion="19"
android:maxSdkVersion="19" />
<application
android:allowBackup="true"
android:icon="#drawable/ic_launcher"
android:label="#string/app_name"
android:theme="#style/AppTheme" >
<activity
android:name="com.ibma.ibmaapp.MainActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
For the first question - Are you sure you saved the changes to the manifest? Seems silly, but it's a mistake I make all the time.
For the second question - You can change the .apk filename to whatever you'd like; there's no need to keep it the same.
finally it works...
updated Android Studio to 0.8.0
updated my APIs (to API 20: Android L)
changed following project settings: (under "File > Project Structure")
Compile SDK Version: android-L
Build Tools Version: 20.0.0
changed the selected API for the graphical Layout (see link below)
have a look at this blog
(Thank you, Thodoris Bais! ;-) )
Had to change the build.gradle file and add the correct VersionCode
this was the reason why I could not generate apk's with different VersionCodes
it was still set to versionCode=1 though in the manifest it was set to two
I checked the new apk file with the aapt command and the versionCode was set to 2, finally!
Now my last queston would be:
Do I always have to update the AndroidManifest.xml and the build.gradle file on my own - shouldn't they just synchronize?
Best regards,
Christian
I have developed and Simple android application in Java and also uploaded it on play.google.com. I uploaded successfully and also published well and I made all steps to published and save the app.after publishing it is showing on app store.Problem is that when I searched the app on my android device then it give the error of "This item is not compatible with your device". I don't understand why this error is being occurred. Kindly any one tell me how can I make and android app which is compatible with all versions of android or any other method through which my app should sun on all android devices.
Here is my manifest file code:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="sml.sml.pkg"
android:versionCode="1"
android:versionName="1.0" >
<uses-sdk android:minSdkVersion="15" />
<application
android:icon="#drawable/ic_launcher"
android:label="#string/app_name" >
<activity
android:name=".SMLActivity"
android:label="#string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
</application>
</manifest>
There are a number of reasons why this might occur. Most likely you are either:
Not specifying the correct minimum SDK your application is compatible with. To do this, you should add to your AndroidManifest.xml the following.
<uses-sdk android:minSdkVersion="#" />
where the # should be replaced with the integer corresponding to the minimum SDK number your application supports. For example, if your application has features that are supported by Gingerbread (API 10) but not Froyo (API 8), then you should specify the number to be 10. Note that you rarely want to add the android:maxSdkVersion attribute, as this will prevent devices from using your application when new SDK versions are released.
Your application uses a feature that is not supported by your device. This might be the case if you have declared in your manifest the <uses-feature> tag.
Edit:
I just saw the code you added to your original post. Your code, specifically, <uses-sdk android:minSdkVersion="15" />, will prevent Android devices running Android versions lower than 15 from using your device. To allow older versions to use your application, you'll need to lower this number. Make sure you are 100% certain that the SDK you choose supports 100% of the features that your application requires.
you need to provide android:minSdkVersion & android:maxSdkVersion in AndroidManifest.xml.
i think your mobile version is not supported to the version you implemented in your project. So, in Androidmanifest file just follow the following changes as shown......
Androidmanifest.xml
<uses-sdk android:minSdkVersion="7" android:maxSdkVersion="11"/>
provide those versions based on your mobile version also. if you are using android 2.2 means its API level is 8. so provide minSdkVersion as 8.
I've written a first app for Android with Eclipse. I've published it but I'm noticing that on the app page it doesn't show the Android minimum version supported, you can see it here:
https://market.android.com/details?id=com.yellowhouse.everydayquotes
I've searched in the project files and I've found that in project.properties there is the following line:
target=android-15
is that the correct place to set the Android version? Am I missing something? Why does it not appear on the page? Thanks.
the "target=android-15" that you have is for your emulator or your test device which you want to launch your app with
To answer to your question, you need to set the minSDK version in your android manifest file
like that
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="tfe.rma.ciss.be"
android:versionCode="1"
android:versionName="1.0">
<uses-sdk android:minSdkVersion="8" />
</manifest>
To set the minimum required android version for your app, you need to use uses-sdk element inside your AndroidManifest.xml file:
<manifest ...>
<uses-sdk android:minSdkVersion="4" android:targetSdkVersion="7"/>
...
</manifest>
Version 4 means Android 1.6. Read up information on android manifest to see the correct sdk version numbers: http://developer.android.com/guide/topics/manifest/uses-sdk-element.html
i have a question:
How can i import or set a version to my .apk file for recognize upgrading in AppMarkets?
have a good time
You'll find information on versioning your app on this site.
You should declare the version of your app in the manifest file. If it's higher than the one on the android device, it will recognize it as an updated version of your app. This version should be an integer value.
I'm talking about the version code, the versionName is your own choice. the versionCode has to be the integer and incrementing every time you launch an updated version of your app.
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.package.name"
android:versionCode="2"
android:versionName="1.1">
<application android:icon="#drawable/icon" android:label="#string/app_name">
...
</application>
Below is a manifest of one of my library projects. Currently I increase the versionCode and versionName with every change. Is that required?
<?xml version="1.0" encoding="utf-8"?>
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
android:installLocation="preferExternal"
android:versionCode="14"
android:versionName="1.1.7"
package="com.tubala.android" >
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-sdk
android:minSdkVersion="7"
android:targetSdkVersion="11" />
</manifest>
Thanks in advance.
Currently AndroidManifest.xml of Android Library is completely ignored when building application that uses this library. The only thing that is used by aapt tool is package attribute (to generate R class into correct package).
This might be changed in next releases. But I'd say you should keep your versioning anyway. This is a good practice (even if build tools are ignoring it).
android:versionName attribute is not necessary. It's just a version users see when they open your application information in the application manager.
android:versionCode is more important. You must increase it every time you publish your application on the Android Market.