Skip to content

Commit e120647

Browse files
authored
[Xamarin.Android.Build.Tasks] AndroidResourceAnalysisConfig (#4046)
Add an `AndroidResourceAnalysisConfig` entry to `@(AvailableItemName)`, allowing users to use the `@(AndroidResourceAnalysisConfig)` build action on files within a project. Files with the `@(AndroidResourceAnalysisConfig)` build action configures message severity levels produced by the Xamarin Android Designer diagnostics tool, and must follow [the documented schema][0]. [0]: https://aka.ms/androidresourceanalysis
1 parent bcf12a2 commit e120647

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

Documentation/guides/BuildProcess.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1416,6 +1416,13 @@ used to specify the ABI that the library targets. Thus, if you add
14161416
`armeabi-v7a`.
14171417
14181418
1419+
### AndroidResourceAnalysisConfig
1420+
1421+
The Build action `AndroidResourceAnalysisConfig` marks a file as a severity level configuration file for Xamarin Android Designer layout diagnostics tool. This is currently only used in the layout editor and not for build messages.
1422+
1423+
See the [Android Resource Analysis documentation](https://aka.ms/androidresourceanalysis) for more details.
1424+
1425+
14191426
#### Item Attribute Name
14201427
14211428
**Abi** – Specifies the ABI of the native library.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
## Option to enable Android resource analysis checks for Android layout files
2+
3+
* [GitHub 4046](https://github.com/xamarin/xamarin-android/issues/4046):
4+
* Adds a new build action to allow configuring message severity levels in the Xamarin Android Designer diagnostics tool. To use this in your project, add an XML configuration file that follows the format described in the [Android Resource Analysis documentation](https://aka.ms/androidresourceanalysis) and set the build action to `AndroidResourceAnalysisConfig`.

src/Xamarin.Android.Build.Tasks/Xamarin.Android.Common.targets

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -185,6 +185,7 @@ Copyright (C) 2011-2012 Xamarin. All rights reserved.
185185
<AvailableItemName Include="AndroidJavaLibrary" />
186186
<AvailableItemName Include="AndroidJavaSource" />
187187
<AvailableItemName Include="AndroidLintConfig" />
188+
<AvailableItemName Include="AndroidResourceAnalysisConfig" />
188189
<AvailableItemName Include="AndroidNativeLibrary" />
189190
<AvailableItemName Include="AndroidResource" />
190191
<AvailableItemName Include="AndroidBoundLayout" />

0 commit comments

Comments
 (0)