Problem
Several source files in src/Xamarin.Android.Build.Tasks/ use spaces for indentation instead of tabs, violating the repository's .editorconfig rule (indent_style = tab for *.cs files). Other files in the same directories correctly use tabs, making these files inconsistent outliers.
Location
- File 1:
src/Xamarin.Android.Build.Tasks/Tasks/GetAvailableAndroidDevices.cs (221 lines, 165 space-indented lines)
- File 2:
src/Xamarin.Android.Build.Tasks/Utilities/JsonExtensions.cs (88 lines)
- File 3:
src/Xamarin.Android.Build.Tasks/Utilities/MSBuildLinkContext.cs (28 lines)
- File 4:
src/Xamarin.Android.Build.Tasks/Utilities/LlvmIrGenerator/LlvmIrTypeCache.cs (40 lines)
- File 5:
src/Xamarin.Android.Build.Tasks/Utilities/ZipArchiveEntryExtensions.cs (8 lines)
- File 6:
src/Xamarin.Android.Build.Tasks/Utilities/AndroidRuntime.cs (9 lines)
.editorconfig Rule
[*.{cs,csx,java,vb,vbx}]
insert_final_newline = true
indent_style = tab
tab_width = 8
indent_size = 8
max_line_length = 180
Current Code (example from GetAvailableAndroidDevices.cs)
public override bool RunTask ()
{
if (!base.RunTask ())
return false;
All indentation uses 4 spaces ( ) instead of tabs.
Suggested Fix
Convert all leading spaces to tabs in each file. Each 4-space indent level should become one tab character. For example:
public override bool RunTask ()
{
if (!base.RunTask ())
return false;
This is a purely mechanical change — no logic changes needed. You can verify other files in the same directories (e.g., src/Xamarin.Android.Build.Tasks/Tasks/AdjustJavacVersionArguments.cs) already use tabs correctly.
Guidelines
- Use tabs for all indentation (per
.editorconfig)
- Preserve Mono code style: space before
( and [ (e.g., Foo (), array [0])
- Preserve all existing code logic, comments, and structure — only change whitespace
- Ensure each file ends with a final newline (
insert_final_newline = true)
- Do not change any non-indentation whitespace (e.g., alignment spaces after tabs are fine to keep)
Acceptance Criteria
Generated by Nightly Fix Finder for issue #11352 · ● 4.1M · ◷
Problem
Several source files in
src/Xamarin.Android.Build.Tasks/use spaces for indentation instead of tabs, violating the repository's.editorconfigrule (indent_style = tabfor*.csfiles). Other files in the same directories correctly use tabs, making these files inconsistent outliers.Location
src/Xamarin.Android.Build.Tasks/Tasks/GetAvailableAndroidDevices.cs(221 lines, 165 space-indented lines)src/Xamarin.Android.Build.Tasks/Utilities/JsonExtensions.cs(88 lines)src/Xamarin.Android.Build.Tasks/Utilities/MSBuildLinkContext.cs(28 lines)src/Xamarin.Android.Build.Tasks/Utilities/LlvmIrGenerator/LlvmIrTypeCache.cs(40 lines)src/Xamarin.Android.Build.Tasks/Utilities/ZipArchiveEntryExtensions.cs(8 lines)src/Xamarin.Android.Build.Tasks/Utilities/AndroidRuntime.cs(9 lines).editorconfigRuleCurrent Code (example from
GetAvailableAndroidDevices.cs)All indentation uses 4 spaces (
) instead of tabs.Suggested Fix
Convert all leading spaces to tabs in each file. Each 4-space indent level should become one tab character. For example:
This is a purely mechanical change — no logic changes needed. You can verify other files in the same directories (e.g.,
src/Xamarin.Android.Build.Tasks/Tasks/AdjustJavacVersionArguments.cs) already use tabs correctly.Guidelines
.editorconfig)(and[(e.g.,Foo (),array [0])insert_final_newline = true)Acceptance Criteria
(and[)