[T-Mobile Samsung Galaxy Note 3] najoor:
** DISCLAIMER: I AM NOT A DEVELOPER. I DO THIS AS A HOBBY AND SHARE MY FINDINGS IN CASE SOMEONE ELSE FINDS THEM USEFUL. **

** THIS WORKED ON MY DEVICE BUT IT MAY NOT WORK ON YOURS. APPLY AT YOUR OWN RISK **​

Background

This script is written for the sole purpose of reducing the power consumption of Android 5.0 update for T-Mobile Note 3. A lot more can be removed from the system but that will not make a significant contribution to power.

The debloat script does not really remove anything; it only disables the apps. You can always run the enbloat script to revert it.

THIS SCRIPT IS FOR LOLLIPOP ONLY. WILL NOT WORK ON OTHER ANDROID FLAVORS.

What this script does

Please read below and understand what this script does before you use it. There may be an app on the list that you may actually want to keep.

Removes: FOTA, update, and security vehicles.

Because: these vehicles push "Security Updates" onto the device. If you make the mistake of accepting this security update, even after you root your tablet, it can patch the hole and you will never be able to use the same exploit to root again.

Removes: Google apps including Gmail and Google sync apps except for Maps, Youtube, Chrome, and Voice Search.

Because: Google apps do a lot of bookkeeping, locationing, and internet access in the background with very little benefit to the user, while consuming a lot of power. If you use Gmail my suggestion is to use the default Email program since it allows a better management of the sync schedule and consumes less battery (and a few other good things). Note that this can severely limit your access to Play Store so either install all store apps you need before debloating or use sideloading to install them after

Removes: Knox

Because: I am yet to meet a single person who likes this nightmare of an app.

Removes: Tmobile stuff except for Voice mail and hotspot

Because: Tmobile bloat does too much activity in the background. In particular, Lookout scans your device constantly to no obvious advantage.

Removes: Backup/cloud agents

Because: Most advanced users backup their data through other means

Removes: Remote control and tracking mechanisms

Because: If you are reading this you most likely don't want your device to be remotely tracked or controlled by Samsung

Removes: ANT services, health, INDI (v2), secgba (v2), Peel (v2)

Because: They run in the background and use the radio.

Removes: Weather (unified) daemon

Because: Major battery hog

Removes: Chat ON, Gear Manager Stub, Bloomberg

Because: Not particularly useful and can be installed from the market if needed

Removes: Enterprise and VPN tools

Because: Most users don't use them

And since someone will ask at some point, no, this script won't trip your Knox!

Requirements:

Rooted Samsung Note 3 SM-N900T (T-mobile model) on Lollipop N900TUVUFOB6. See this thread.

Android Terminal Emulator: https://play.google.com/store/apps/details?id=jackpal.androidterm&hl=en

Download link:

Attached below

Instructions:

Make a backup of your files/system. Also have a flashable Odin ROM handy to recover from possible disasters. I am not responsible if you brick your device while using these scripts.

To debloat:

1- Unzip the attachment and copy debloat.sh to your phone at /sdcard

2- Run the terminal emulator and type the following:

su

cd /sdcard

sh debloat.sh​

3- It will do its thing and reboot your phone in about 5 seconds.

To restore the bloatware:

1- Unzip the attachment and copy enbloat.sh to your phone at /sdcard

2- Run the terminal emulator and type the following:

su

cd /sdcard

sh enbloat.sh​

3- It will do its thing and reboot your phone in about 5 seconds. You have all your bloat back now.

Note that while running the debloat script you may get force-closing popups. This is normal; after all you are disabling these applications.

Limitations:

If you have previously removed bloat using other means this script CANNOT recover it for you. enbloat.sh can only restore what debloat.sh has disabled.

Final Notes

With this script you should be able to get anywhere between 0.25 to 1 percent discharge per hour in standby mode. Your awake time should also be around 1-3%. You will still find that Google Services will wake up and use GPS every time you unlock your phone. To get even better battery performance turn your GPS off when you are not using it

This should be sufficient for 99% of people. After you apply this script, if you still want more try this: Disable Phonesky, google play services, Google framework, and stock YouTube by renaming their apks (not the directory they are in but the apks themselves) to .apk.bac, reboot, and install an older version of youtube that does not need Google Services, such as 5.1.10. Note that this drastic removal of Google services will make assisted GPS very slow in Google Maps. If you don't understand what that means it is best to stick with the debloat script and not mess with your system.

Regardless of whether you end up using this code or not, my suggestion to you is to go to Settings -> General -> Security -> Security Policy Updates -> untick Automatic Updates.

Update

Version 2 removes more background processes. If you have already used version 1 to debloat, I recommend that you use version 1 to restore the bloat and then use version 2 to debloat again.