LineageOS 14.1 Nougat Debloat Script [06/22/17]

Search This thread

lieferant

Member
Jan 4, 2015
44
40
I have no need for the standard apps that come with LineageOS (formerly CM), because these apps are replaced by Gapps anyways. So I created a script that you can flash immediatelly after flashing a new ROM in order to have a clean install and remove these apps from the system.

Credits @Gawd for the inspiration.

What will be removed?

The script as is, will remove the following CM/LineageOS apps:

  • Calendar
  • CMFileManager
  • DeskClock
  • Eleven (Music)
  • Email
  • Calculator
  • Exchange
  • Gello (CM browser)
  • Screencast
  • AudioFX
  • Contacts
  • AS OF 01.March 17 - Android Browser
  • AS OF 01.March 17 - Substratum
  • AS OF 25.March 17 - Masquerade App
  • AS OF 25.March 17 - Pico TTS
  • AS OF 22.June 17 - Documents
  • AS OF 22.June 17 - Messaging
  • AS OF 22.June 17 - Phone
  • AS OF 22.June 17 - Daydream
  • AS OF 22.June 17 - Jelly
  • AS OF 22.June 17 - Snap Camera
  • AS OF 22.June 17 - Gallery2
  • AS OF 22.June 17 - LivePhotos
  • AS OF 22.June 17 - WallpaperTable


How to apply?

It's best to stick to a certain installation order to make sure to avoid conflicts.

My suggested way of installing a ROM is like that:

  1. Deep wipe
  2. Install ROM
  3. Install alternative kernel if you wish
  4. Run debloat script
  5. Install Gapps
  6. Reboot

What else?

This script will survive dirty flashes as well as ota updates. So there's no apparent need to flash it again after that. Clean flashes will ofcourse need it to be flashed again.

I would like to remove more / less apps...

No problem. Just follow these instructions:

OK now, we are good to go:

1. Download and install Notepad++
2. Download the attached .zip file and extract it. Go to META-INF → com → google → android.
Now you will see a filed named updater-script. This it the file that will do all the magic, so be careful. Now: right click on it and open it with Notepad++.

3. Now on Notepad++
a) Select Encoding → Encode in ANSI
b) Select Edit → EOL Conversion → UNIX/OSX Format (not necessary in all cases)

4. Go ahead an add or remove apps as you wish.
Code:
delete_recursive(
	"/system/app/Calendar",
	"/system/app/CMFileManager",
	"/system/app/DeskClock",
	"/system/priv-app/Eleven",  >>>> [COLOR="Red"]Changed to priv-app as of 15.08.2017 [/COLOR]
	"/system/app/Email",
	"/system/app/ExactCalculator",
	"/system/app/Exchange2",
	"/system/app/Gello",
        "/system/app/Substratum", >>>> [COLOR="Red"]New as of 01.03.2017 [/COLOR]
        "/system/app/Browser", >>>> [COLOR="Red"]New as of 01.03.2017 [/COLOR]
        "/system/priv-app/masquerade",>>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
	"/system/priv-app/Recoder", >>>> [COLOR="Red"]New as of 31.01.2017 - replaces Screencast App[/COLOR]
	"/system/priv-app/AudioFX",
	"/system/priv-app/Contacts",
	"/system/tts", >>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
	"/system/lib/libttspico.so", >>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
	"/system/app/PicoTts", >>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
"/system/priv-app/DocumentsUI", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/app/messaging", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/app/BasicDreams", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/priv-app/Dialer", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/priv-app/Gallery2", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/app/PhotoTable", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/app/LiveWallpapersPicker", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/app/Jelly", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
	"/system/priv-app/Snap" >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
);

5. Now save the updater-script and exit from Notepad++.

6. The next thing to do is create the flashable zip.

a) Make sure that the updater-scipt is in META-INF → com → google → android
b) Make sure the folder "system" in the root directory is empty.
c) Select both META-INF and system folder and right click on them.
d) Select Add to archive.
e) Archive format: ZIP
f) Compression method Store
---> The Archive format and the Compression method are very important, so make sure they are ZIP and STORE.
g) Now copy the zip file you created in your phone and flash it!

That's it.
 

Attachments

  • LineageOS_14.1_Debloater_31012017_lieferant.zip
    291.2 KB · Views: 1,893
  • LineageOS_14.1_Debloater_01032017_lieferant.zip
    291.3 KB · Views: 370
  • LineageOS_14.1_Debloater_25032017_lieferant.zip
    291.4 KB · Views: 916
  • LineageOS_14.1_Debloater_22062017_lieferant.zip
    179.8 KB · Views: 3,385
Last edited:

xxqxpxx

Senior Member
Oct 14, 2014
363
29
26
banha
i tried applying your method in ubuntu 16 but i failed with error 6 . any ideas how to do it ? i want to remove those apps

"/system/app/Calendar",
"/system/app/CMFileManager",
"/system/app/Eleven",
"/system/app/Email",
"/system/app/Exchange2",
"/system/app/Gello",
"/system/app/Browser",
"/system/app/AntHalService",
"/system/app/Basic-Dreams",
"/system/app/LatinIME",
"/system/app/webview",
"/system/app/Gallery2",
"/system/app/messaging",
"/system/app/PicoTts",
"/system/app/Wallpaper",
"/system/priv-app/AudioFX",
"/system/priv-app/DocumentsUI",
"/system/priv-app/MusicFX",
 

Gawd

Senior Member
Jan 26, 2015
1,248
1,817
i tried applying your method in ubuntu 16 but i failed with error 6 . any ideas how to do it ? i want to remove those apps

"/system/app/Calendar",
"/system/app/CMFileManager",
"/system/app/Eleven",
"/system/app/Email",
"/system/app/Exchange2",
"/system/app/Gello",
"/system/app/Browser",
"/system/app/AntHalService",
"/system/app/Basic-Dreams",
"/system/app/LatinIME",
"/system/app/webview",
"/system/app/Gallery2",
"/system/app/messaging",
"/system/app/PicoTts",
"/system/app/Wallpaper",
"/system/priv-app/AudioFX",
"/system/priv-app/DocumentsUI",
"/system/priv-app/MusicFX",
Remove the last comma, after MusicFX

This should do :)
 

Hubird

Senior Member
Dec 18, 2015
151
36
Thanks a lot for this, exactly what I was looking for.

I added

"/system/priv-app/Gallery2", (Glaery3D app, can use Google photos or one of the other million, regularly updated app available from the Play Store)
"/system/app/messaging", (AOSP messaging app, as above but Google messaging)

To mine and I thinks that's all the bloat gone.
 

Flynhx

Senior Member
Jun 16, 2015
288
80
26
/system/lost+found
Why didn't i see this before? Every clean flash for every build update on my LineageOS 13.0, i always delete the bloatware apps manually and i know it is a pain in the ass. Even if your running LineageOS 13.0, you can still use this. I've add/remove some apps for my personal taste. Very much thanks for this script! :D
 

Ibuprophen

Senior Member
Sep 4, 2012
9,545
6,496
Upstate New York
@lieferant, I am (almost) completely speechless!

I noticed a recommendation and a link to this thread within another thread that I follow from @githyanki to another and had to check it out.

I've got to admit that this is a really great idea and, out of pure curiosity (and by nature... LOL!), am forced to test this out.

I am amazed that, though chatted about, nobody i can think of has ever taken this idea from concept to release.

What a great idea indeed and will report my results here for you to take note.

Thank you very much lieferant!


"Live Long and Prosper..."
~Ambassador S'chn T'gai Spock

Sent via Communicator [D2VZW] from the Bridge of the U.S.S. Enterprise
 
Last edited:

tomatosmoothie

Senior Member
Jul 17, 2017
119
28
Awesome!

Awesome script, thank you for your work.

Noticed that 2 LOS Stock apps did not get removed.
1) Camera App
2) The eleven music app

This is for the latest LineageOS at the time of this post on the OnePlus2.

Thanks again :)

Update 1:

After going through your initial post I made some additions to the script to get what I need

I used this post to flash OnePlus Camera and OnePlus Gallery

"/system/media/audio/ui/camera_click.ogg", <--Removes camera click sounds for any camera
"/system/media/audio/ui/camera_focus.ogg", <--Removes other camera sound
"/system/media/audio/ui/VideoRecord.ogg", <--Removes video recording sound
"/system/media/audio/ui/VideoStop.ogg", <--- Removes other video recording sound
"/system/app/Camera2", <--- Removes the LineageOS stock Camera
"/system/priv-app/OnePlusGallery" <--- Removes OnePlusGallery if installed via the link above
Code:
        "/system/media/audio/ui/camera_click.ogg",
	"/system/media/audio/ui/camera_focus.ogg",
	"/system/media/audio/ui/VideoRecord.ogg",
	"/system/media/audio/ui/VideoStop.ogg",
	"/system/app/Camera2",
	"/system/priv-app/OnePlusGallery"

Add the above script based on the initial post in this thread!
 
Last edited:

david72262

Senior Member
  • Jul 3, 2013
    1,988
    1,796
    Oregon
    OnePlus One
    OnePlus 6T
    Awesome script, thank you for your work.

    Noticed that 2 LOS Stock apps did not get removed.
    1) Camera App
    2) The eleven music app

    This is for the latest LineageOS at the time of this post on the OnePlus2.

    Thanks again :)

    Update 1:

    After going through your initial post I made some additions to the script to get what I need

    I used this post to flash OnePlus Camera and OnePlus Gallery

    "/system/media/audio/ui/camera_click.ogg", <--Removes camera click sounds for any camera
    "/system/media/audio/ui/camera_focus.ogg", <--Removes other camera sound
    "/system/media/audio/ui/VideoRecord.ogg", <--Removes video recording sound
    "/system/media/audio/ui/VideoStop.ogg", <--- Removes other video recording sound
    "/system/app/Camera2", <--- Removes the LineageOS stock Camera
    "/system/priv-app/OnePlusGallery" <--- Removes OnePlusGallery if installed via the link above


    Add the above script based on the initial post in this thread!
    So the oneplus 5 camera port for the oneplus2 works on bacon?
     

    Top Liked Posts

    • There are no posts matching your filters.
    • 29
      I have no need for the standard apps that come with LineageOS (formerly CM), because these apps are replaced by Gapps anyways. So I created a script that you can flash immediatelly after flashing a new ROM in order to have a clean install and remove these apps from the system.

      Credits @Gawd for the inspiration.

      What will be removed?

      The script as is, will remove the following CM/LineageOS apps:

      • Calendar
      • CMFileManager
      • DeskClock
      • Eleven (Music)
      • Email
      • Calculator
      • Exchange
      • Gello (CM browser)
      • Screencast
      • AudioFX
      • Contacts
      • AS OF 01.March 17 - Android Browser
      • AS OF 01.March 17 - Substratum
      • AS OF 25.March 17 - Masquerade App
      • AS OF 25.March 17 - Pico TTS
      • AS OF 22.June 17 - Documents
      • AS OF 22.June 17 - Messaging
      • AS OF 22.June 17 - Phone
      • AS OF 22.June 17 - Daydream
      • AS OF 22.June 17 - Jelly
      • AS OF 22.June 17 - Snap Camera
      • AS OF 22.June 17 - Gallery2
      • AS OF 22.June 17 - LivePhotos
      • AS OF 22.June 17 - WallpaperTable


      How to apply?

      It's best to stick to a certain installation order to make sure to avoid conflicts.

      My suggested way of installing a ROM is like that:

      1. Deep wipe
      2. Install ROM
      3. Install alternative kernel if you wish
      4. Run debloat script
      5. Install Gapps
      6. Reboot

      What else?

      This script will survive dirty flashes as well as ota updates. So there's no apparent need to flash it again after that. Clean flashes will ofcourse need it to be flashed again.

      I would like to remove more / less apps...

      No problem. Just follow these instructions:

      OK now, we are good to go:

      1. Download and install Notepad++
      2. Download the attached .zip file and extract it. Go to META-INF → com → google → android.
      Now you will see a filed named updater-script. This it the file that will do all the magic, so be careful. Now: right click on it and open it with Notepad++.

      3. Now on Notepad++
      a) Select Encoding → Encode in ANSI
      b) Select Edit → EOL Conversion → UNIX/OSX Format (not necessary in all cases)

      4. Go ahead an add or remove apps as you wish.
      Code:
      delete_recursive(
      	"/system/app/Calendar",
      	"/system/app/CMFileManager",
      	"/system/app/DeskClock",
      	"/system/priv-app/Eleven",  >>>> [COLOR="Red"]Changed to priv-app as of 15.08.2017 [/COLOR]
      	"/system/app/Email",
      	"/system/app/ExactCalculator",
      	"/system/app/Exchange2",
      	"/system/app/Gello",
              "/system/app/Substratum", >>>> [COLOR="Red"]New as of 01.03.2017 [/COLOR]
              "/system/app/Browser", >>>> [COLOR="Red"]New as of 01.03.2017 [/COLOR]
              "/system/priv-app/masquerade",>>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
      	"/system/priv-app/Recoder", >>>> [COLOR="Red"]New as of 31.01.2017 - replaces Screencast App[/COLOR]
      	"/system/priv-app/AudioFX",
      	"/system/priv-app/Contacts",
      	"/system/tts", >>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
      	"/system/lib/libttspico.so", >>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
      	"/system/app/PicoTts", >>>> [COLOR="Red"]New as of 25.03.2017 [/COLOR]
      "/system/priv-app/DocumentsUI", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/app/messaging", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/app/BasicDreams", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/priv-app/Dialer", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/priv-app/Gallery2", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/app/PhotoTable", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/app/LiveWallpapersPicker", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/app/Jelly", >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      	"/system/priv-app/Snap" >>>> [COLOR="Red"]New as of 22.06.2017 [/COLOR]
      );

      5. Now save the updater-script and exit from Notepad++.

      6. The next thing to do is create the flashable zip.

      a) Make sure that the updater-scipt is in META-INF → com → google → android
      b) Make sure the folder "system" in the root directory is empty.
      c) Select both META-INF and system folder and right click on them.
      d) Select Add to archive.
      e) Archive format: ZIP
      f) Compression method Store
      ---> The Archive format and the Compression method are very important, so make sure they are ZIP and STORE.
      g) Now copy the zip file you created in your phone and flash it!

      That's it.
      3
      Credits: @Setting.Out for explaining me things ?
      2
      i tried applying your method in ubuntu 16 but i failed with error 6 . any ideas how to do it ? i want to remove those apps

      "/system/app/Calendar",
      "/system/app/CMFileManager",
      "/system/app/Eleven",
      "/system/app/Email",
      "/system/app/Exchange2",
      "/system/app/Gello",
      "/system/app/Browser",
      "/system/app/AntHalService",
      "/system/app/Basic-Dreams",
      "/system/app/LatinIME",
      "/system/app/webview",
      "/system/app/Gallery2",
      "/system/app/messaging",
      "/system/app/PicoTts",
      "/system/app/Wallpaper",
      "/system/priv-app/AudioFX",
      "/system/priv-app/DocumentsUI",
      "/system/priv-app/MusicFX",
      Remove the last comma, after MusicFX

      This should do :)
      2
      @lieferant, I am (almost) completely speechless!

      I noticed a recommendation and a link to this thread within another thread that I follow from @githyanki to another and had to check it out.

      I've got to admit that this is a really great idea and, out of pure curiosity (and by nature... LOL!), am forced to test this out.

      I am amazed that, though chatted about, nobody i can think of has ever taken this idea from concept to release.

      What a great idea indeed and will report my results here for you to take note.

      Thank you very much lieferant!


      "Live Long and Prosper..."
      ~Ambassador S'chn T'gai Spock

      Sent via Communicator [D2VZW] from the Bridge of the U.S.S. Enterprise
      2
      Please keep the desk clock and contact app, too. Thank you very much

      You do realize that you can pretty much edit the script yourselves right?...The instructions are clear on the lieferant first post. Anyway it doesn't take long to edit, less than a minute, but this will be my last script edit, because it defeats the purpose of lieferant putting in clear instructions on how to edit it versus letting somebody just edit it for you. That's just plain lazy on your part.

      Here ya go. Contacts, Dialer and Desk clock will not be removed.
    Our Apps
    Get our official app!
    The best way to access XDA on your phone
    Nav Gestures
    Add swipe gestures to any Android
    One Handed Mode
    Eases uses one hand with your phone