[Huawei P10 Plus Guides, News, & Discussion] GryphonBR:
Hi everyone,

I recently got a P10 Plus and one of the things I was most excited about was App Twin. I've used this feature previously on a Xiaomi Note 3 Pro I had, but upon searching around I couldn't find any working methods for EMUI 8 (and, matter of fact, the one available here on XDA to add any app you want didn't seem to work. I started to poke around on my own, and am very happy to report I figured a way to enable App Twin for any app you want; unfortunately, at this point, the method I've found requires root access to work, but hopefully someone around will manage to figure a way to make this unnecessary eventually. So, without further ado, here goes.

First off, follow this very helpful tutorial to ensure the feature will be enabled in your phone (I have yet to try out the remaining of this guide without doing this, so if anyone wants to do that, be my guest :D ).

Next, we need to figure out exactly what the package name for the desired app is. For example, Gmail's is com.google.android.gm, and I figure the easiest way to find out the exact name is to look over Magisk Hide (yeah, I use Magisk for all my rooting needs). If the app's already installed, my piece of advice would be to back it up with Titanium Backup or something, just for the sake of being thorough and specially if it's a system app, which is a subject I'll touch in a few.

Now, for the fun part: Huawei changed how App Twin looks for enabled apps to execute its functionality, so we're gonna need to edit the file /system/emui/base/xml/hw_clone_app_list.xml

Here's the original content of mine:

<?xml version="1.0" encoding="utf-8"?>
<!-- DTS2016060606663 shiyuanchang/00271386 20160704 created -->
<AppClone>
<package name="com.tencent.mm"/>
<package name="com.tencent.mobileqq"/>
<package name="com.facebook.katana"/>
<package name="com.whatsapp"/>
<package name="jp.naver.line.android"/>
<package name="com.snapchat.android"/>
<package name="com.facebook.orca"/>
</AppClone>

And this part should be fairly trivial to most fellow XDA members: you simply append whatever program you feel like cloning to the list. Like so:

<?xml version="1.0" encoding="utf-8"?>
<!-- DTS2016060606663 shiyuanchang/00271386 20160704 created -->
<AppClone>
<package name="com.tencent.mm"/>
<package name="com.tencent.mobileqq"/>
<package name="com.facebook.katana"/>
<package name="com.whatsapp"/>
<package name="jp.naver.line.android"/>
<package name="com.snapchat.android"/>
<package name="com.facebook.orca"/>
<package name="com.google.android.gm"/>
<package name="com.amazon.venezia"/>
<package name="com.amazon.mShop.android.shopping"/>
</AppClone>

As you might have noticed, I added 3 apps: Gmail, Amazon Appstore and Amazon Shopping. I added the first two just for the sake of testing, but specifically for Amazon Shopping it'd be helpful for me since I have a US and a Canadian accounts, so... Anyway, beside the point, which was: I added both Amazon apps to the list before installing them, so that was a no brainer - upon installation, they showed up on Settings as clonable, if you wish. The trouble was with Gmail, since it's a system app; when I added the entry to the XML file, it immediately appeared on the list as well, but as already cloned despite no cloned app showing on the launcher, and I also couldn't flip to switch to deactivate/reactivate the functionality. So, what I ended up doing was using a Magisk module called Debloater, which is by the way very neat in allowing anyone to systemlessly debloat your phone. Through the module, I uninstalled Gmail, rebooted the phone, reinstalled it, rebooted yet again and voilà, Gmail clone app showed in the launcher as expected.

Oh, and something I totally forgot to mention: should you use any launcher other than Huawei's default, this method's got you covered without any extra kinks. I'm using Nova and both Amazon Shopping apps show up just as they would on Huawei Home (I also tested it on ADW Launcher and it works, but YMMV).

All in all, this guide shouldn't be overly complicated to anyone. And I know, needing root to achieve this is somewhat of a nuisance, but well... My phone is already rebranded (since my operator has decided to block any and all updates since November) and the bootloader was unlocked, so I would have needed Magisk one way or the other, and getting that extra something from this amazing device just seemed fair after all the trouble I had to go through to install the latest Oreo build into it. Hope you guys enjoy it, and should anyone around decide to experiment a little further (say enable extra apps without modifying the local.prop file, for instance, or finding out how an non-system app already installed would behave when using this method), feel free to give me a shout here and I'll update this guide later on.

Peace and have fun with your devices!