Your XML file is mostly correct, but there are a few minor issues with your closing tags and the placement of tools:replace, which seems incorrect as you've placed it outside of any specific element.
I'll correct these issues and indicate the places where you intended to write "write wherever there is a mistake":
- Correct the
tools:replace placement. It looks like it was intended to be inside the <application> tag attributes but was mistakenly placed below it.
- Ensure all tags are properly closed and structured.
Here’s a corrected version of your AndroidManifest.xml, with comments indicating the corrected lines:
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
<uses-permission android:name="android.permission.INTERNET" />
<uses-permission android:name="android.permission.CAMERA" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
<uses-feature
android:name="android.hardware.camera.any"
android:required="false" />
<uses-feature
android:name="android.hardware.camera.autofocus"
android:required="false" />
<application
android:name=".App"
android:allowBackup="false"
android:hardwareAccelerated="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:largeHeap="true"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AuthActivity"
tools:replace="android:allowBackup"> <!-- Corrected: tools:replace placement -->
<provider
android:name=".presentation.pdf.GenericFileProvider"
android:authorities="${applicationId}.provider"
android:exported="false"
android:grantUriPermissions="true">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/provider_paths" />
</provider>
<activity android:exported="true"
android:name=".presentation.splash.activity.ActivitySplash"
android:screenOrientation="portrait"
android:theme="@style/AuthActivity">
<tools:validation testUrl="https://jjpwebdev.medicdigital.com/auth-code/test2" />
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
<intent-filter android:autoVerify="true">
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="${hostName}"
android:pathPattern="/auth-code/.*"
android:scheme="https" />
</intent-filter>
<intent-filter>
<action android:name="android.intent.action.VIEW" />
<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />
<data
android:host="jnjpodcastdev.ichannelmedia.com"
android:pathPrefix="/share/redirect"
android:scheme="https" />
</intent-filter>
</activity>
<!-- Remaining activities and services -->
<meta-data
android:name="com.google.android.gms.version"
android:value="@integer/google_play_services_version"
tools:replace="android:value" /> <!-- Correctly placed inside the application tag -->
</application>
</manifest>
The key correction was to ensure the tools:replace="android:allowBackup" attribute is correctly placed inside the <application> start tag. Also, it is important to ensure that all tags are correctly opened and closed, providing a valid XML format for the Android Manifest. Please replace the comment <!-- Remaining activities and services --> with the rest of your components, as they were not the focus of this correction.