unoplatform/uno

`Package.Current.Id` Not providing right `Build/Revision` number for mobile

Open

#11,216 建立於 2023年2月6日

在 GitHub 查看
 (3 留言) (0 反應) (0 負責人)C# (837 fork)batch import
difficulty/starter 🚀good first issuehacktoberfestkind/bugno-reproproject/non-ui ⚙️

倉庫指標

Star
 (9,789 star)
PR 合併指標
 (平均合併 14天 8小時) (30 天內合併 130 個 PR)

描述

Current behavior

The current Uno implementation only make use of versionName for Android and CFBundleShortVersionString for iOS when it should also use versionCode for Android and CFBundleVersion for iOS as Build/Revision value. See Uno documentation for more details.

So currently we must use a version with 4 numbers if we want to have the Build/Revision information in our application but on iOS they must absolutely be separated because the version as to be composed of 3 numbers. See Apple documentation for more details.

The implementation should resemble Xamarin/MAUI Essentials a bit more for application version reading. See MAUI repositery for more details.

Expected behavior

Revision value should use versionCode for Android and CFBundleVersion for iOS or we should have an extension for the build if it's more than one digit. Whatever is best to make use of every mobile version variable.

How to reproduce it (as minimally and precisely as possible)

No sample needed, it's working but limiting our application.

Workaround

Use Xamarin/MAUI Essentials.

Works on UWP/WinUI

Yes

Environment

Uno.UI / Uno.UI.WebAssembly / Uno.UI.Skia, Uno.WinUI / Uno.WinUI.WebAssembly / Uno.WinUI.Skia

NuGet package version(s)

No response

Affected platforms

Android, iOS, Windows

IDE

Visual Studio 2022

IDE version

17.4.4

Relevant plugins

No response

Anything else we need to know?

No response

貢獻者指南