mirror of
https://github.com/ppy/osu
synced 2024-12-12 09:58:22 +00:00
76367444cb
With .NET 6, the way Xamarin package versioning works has changed.
- The `ApplicationVersion` MSBuild property aims to replace
`android:versionCode` in the manifest.
- The `ApplicationDisplayVersion` MSBuild property aims to replace
`android:versionName` in the manifest.
More about this can be read in Xamarin docs:
ec712da8c1/Documentation/guides/OneDotNetSingleProject.md
To this end:
- Manual `version{Code,Name}` specs are removed from
`AndroidManifest.xml`, as they were preventing MSBuild properties
from functioning properly.
- `Version` now defaults to 0.0.0, so that local builds don't appear
like they were deployed (see `OsuGameBase.IsDeployedBuild`).
- `ApplicationDisplayVersion` now defaults to `Version`.
This addresses the Android portion of #21498.
- `ApplicationVersion` can now be specified by command line,
but still needs to be supplied manually for version detection to
work correctly. See `OsuGameAndroid.AssemblyVersion` for more info.
Putting the pieces together, the complete publish command to deploy
a new build should look something like so:
dotnet publish -f net6.0-android \
-r android-arm64 \
-c Release \
-p:Version=2022.1228.0 \
-p:ApplicationVersion=202212280
5 lines
374 B
XML
5 lines
374 B
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android" package="sh.ppy.osulazer" android:installLocation="auto">
|
|
<uses-sdk android:minSdkVersion="21" android:targetSdkVersion="31" />
|
|
<application android:allowBackup="true" android:supportsRtl="true" android:label="osu!" android:icon="@drawable/lazer" />
|
|
</manifest> |