Setting native version numbers with capacitor #3164
-
With cordova, we could configure a few version numbers using attributes on the tag in config.xml. |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 2 replies
-
This is currently not supported with capacitor. You have to do it yourself in the native IDEs. |
Beta Was this translation helpful? Give feedback.
-
As tavosansal said, you have to do it in the native IDEs. This is the information about iOS: If you open the For Android you have to change it in the App's If you build in a CI/CD platform, tools such as fastlane allow to increment the version automatically. |
Beta Was this translation helpful? Give feedback.
-
There's now support for this in Trapeze: https://trapeze.dev |
Beta Was this translation helpful? Give feedback.
-
I must say, one of the best reasons to use Ionic is to stay as far away from the native IDE's as possible; it's in fact the entire reason I chose this platform in the first place. Because like me, many of us don't have macs so we can't possibly open XCode to do "x,y, and z". Removing the ability to set build numbers at an "ionic" level in favor of having to do it at the native IDE level seems like a regression for the framework :( I really hope this doesn't become a trend. |
Beta Was this translation helpful? Give feedback.
As tavosansal said, you have to do it in the native IDEs.
This is the information about iOS:
https://capacitorjs.com/docs/ios/configuration#configuring-info-plist
If you open the
Info.plist
file as Property List (default), they are theBundle version string (short)
field andBundle version
. If opening as source code they areCFBundleShortVersionString
andCFBundleVersion
. First one is the version string and the second the version number.For Android you have to change it in the App's
build.gradle
file changingversionName
andversionCode
.If you build in a CI/CD platform, tools such as fastlane allow to increment the version automatically.