Add values to AndroidManifest?


#1

Basicly I need to add some values to the manifest, how would I go about doing that in fuse?
The values are as follows:

<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED"/>

<receiver android:name=".BootReceiver" android:enabled="true" android:exported="true">
            <intent-filter>
                <category android:name="android.intent.category.DEFAULT"/>
                <action android:name="android.intent.action.BOOT_COMPLETED"/>
                <action android:name="android.intent.action.QUICKBOOT_POWERON"/>
                <!--For HTC devices-->
                <action android:name="com.htc.intent.action.QUICKBOOT_POWERON"/>
            </intent-filter>
        </receiver>

#2

Hey @Palton, checkout the manifest section in the docs here: https://fuseopen.com/docs/native-interop/build-settings.html


#3
[Require("AndroidManifest.RootElement", "<uses-permission android:name=\"android.permission.RECEIVE_BOOT_COMPLETED\"/>")]

[Require("AndroidManifest.RootElement", "<receiver android:name=\".BootReceiver\" android:enabled=\"true\" android:exported=\"true\">")]
[Require("AndroidManifest.RootElement", "  <intent-filter>")]
[Require("AndroidManifest.RootElement", "       <category android:name=\"android.intent.category.DEFAULT\"/>")]
[Require("AndroidManifest.RootElement", "       <action android:name=\"android.intent.action.BOOT_COMPLETED\"/>")]
[Require("AndroidManifest.RootElement", "       <action android:name=\"android.intent.action.QUICKBOOT_POWERON\"/>")]
[Require("AndroidManifest.RootElement", "       <!--For HTC devices-->")]
[Require("AndroidManifest.RootElement", "       <action android:name=\"com.htc.intent.action.QUICKBOOT_POWERON\"/>")]
[Require("AndroidManifest.RootElement", "   </intent-filter>")]
[Require("AndroidManifest.RootElement", "</receiver>")]

This is a example of adding some values to android manifest.
Don’t forget to add back slash in front of double quote in each elements string.