Adding tweaks/scripts - Android Q&A, Help & Troubleshooting

How do I add scripts/tweaks to my rom properly? For ex. I want to add the operation kill joy script to my rom which is build from kitchen.

If that is simple script(one file)-just place it into init.d folder and it will be executed on every boot. But you will need kernel with init.d support.

Related

APK Manager v4.9 (Easy way to edit APKs)

Hey guys...heres the APK manager v4.9 by daneshm90.....its an easy way to edit apks......​
So i have written a simple script to ease the process of editing apks. Got a lot of downloads so thought its in demand
Whether you're doing basic image editing or editing the smali or xml files, on average u have to use (Brut.all or JF's smali/baksmali) awesome tool to extract the apk, edit it, then sign the apk and then adb push/install it. This process is quite tiresome if you are testing a method that needs fine tweaking.
This script should make the process a LOT smoother.
Theres an option of compiling/signing/installing all in one step
Thanks:
Goes to Brut.all for his awesome tool.
Goes to JF for ofcourse, smali/baksmali
Goes to farmatito for porting this script to linux
Features:
- Extract, Zip apk's.
- Optimize pngs (ignores .9.pngs)
- Zipalign apks
- Sign apks
- Push to specific location on phone
- Incorporates brut.all's apktool
- Pull apk from phone into modding environment.
- Batch optimize apk (Zipalign,optipng,or both)
- Quick sign an apk (Batch mode supported)
- Batch Ogg optimization
- Compression level selector (monitor status above menu)
- Batch install apk from script (option 16)
- Logging on/off has been removed. Instead a log.txt is created which logs the activities of the script organized using time/date headers
- User can change the max java heap size (only use if certain large apks get stuck when decompiling/compiling apks) (Option 19)
- Improved syntax of questions/answers
- Error detection. Checks if error occured anytime u perform a task, and reports it
- Read log (Option 20)
- U can now set this script as ur default application for apks. When u do, if u double click any apk it will install it for u.
- Supports batch installation, so if u drag multiple apks into the script (not while its running) it will install them all for u. U can ofcourse drag a single apk as well
- Added framework dependent decompiling (For non propietary rom apks). (Option 10). Checks whether the dependee apk u selected is correct.
- Allows multiple projects to be modified, switch to and from.
- Allows to modify system apk's using apktool but ensures maximum compatibility in terms of signature / manifest.xml
- Stuff i forgot i guess
Instructions (Windows):
- Place apk in appropriate folder (Any filename will work, if running for first time folders will not be there, you must run and then the folders will be created)
- Run script
- Minimize the script
- Edit files inside the project folder
- Maximize the script
Instructions (Linux):
- Place apk in appropriate folder (Any filename will work, if running for first time folders will not be there, you must run and then the folders will be created)
- Open terminal and change-directory to apkmanager (Easiest way is to type "cd ")
- Chmod 755 Script.sh
- Chmod 755 all files apps inside other folder (thanks for the tip bkmo )
- Run script by typing ./Script.sh
- Minimize the script
- Edit files inside the out folder
- Maximize the script
Requirements:
Java
Adb
Future Improvements:
- Manage multiple simultaneous apk edits (choose which apk to extract/build)
- Option to optimize the apks
- Option to adb push to user defined location
- Other stuff i dont know yet.
Windows (v4.9): Download Here
Linux (v4.3): Download Here
Here's the video!!
Got problems ?
1. Make sure your path has no spaces
2. Your filename has no wierd characters
3. Java/adb are in your path
4. It's not a proprietary rom's apk (aka Sense,Motorola,Samsung) (If u are, then use option 11 and drag the required framework, eg com.htc.resources, twframework-res...etc)
5. It's not a themed apk (if it is, expect .9 png errors, use as close to stock as possible)
6. Look at the log to know whats happening
7. If all else fails, post as much info as possible and we will try to assist you.
If U like my post, press the Thumbs Up button, i.e, Thank Me!
Bad download link. Please fix?
Please download to mediafire or multiupload
thanks
actually its not death214 link or project..and all thread he started was project by others and he just copy and paste..i remember u've been scolded by owain becoz of this,right death?=)
please upload files to other site.i cant download from rapidshare.
change link
Please click here:
http://lmgtfy.com/?q=apk+manager+xda
Nice. Rapidshare link working flawless.

SCRIPTS e ELG TWEAKS

How do for I add scripts in termimal emulator to save more battery in the touchv6 kernal from PaoloM70? I would like to add some ELG TwEAKS. THX.

[Script]Sick Speed Tweaks

Found this init.d script to boost to performance
http://forum.xda-developers.com/showthread.php?t=1267945
Extract the files and copy them under init.d folder (Work only on DoomKernel) give proper permission.

[kernel][stock][D85520P][init.d][bumped][SELinux permissive] -- SEXY

I wanted to share with you these two simples kernels based on the D85520P, I changed it just to implement the init.d support, for using it with stock rom. Of course, I also have Bumped them.
There are differents ways to proceed, and two points of possible inputs to activate init.d. This can indeed be done directly in the kernel, in ramdisk, or in the system.
For my part, to do this, I modified in two differents ways, the kernel D85520P (ramdisk), that I provide for those who are interested.
The first one uses run-parts, applet typically provided with busybox, and it therefore requires busybox installed on your system. Prioritize it, if you use a busybox that manages run-parts.
The second does not require any third party and will work without special prerequisites.
Both created, at the boot, if it does not exist, the init.d directory with the correct permissions (system/etc/init.d chmod 755).
Theses very simples kernel modificiations, are part of a project on which we work at our own pace, and for the fun, me and @jac10000 .
This unpretentious project will try to make a series of more or less customized , optimized, stock-based rom.
We called this series, our Stock EXperience (for) You (SEXY) ROM
That is why these two simples modified kernels have this name too
These kernels are only for using with pure stock rom:
They are in img format, and can be flashed with TWRP after selecting this format
Kernel D85520P bumped and with ramdisk implementing init.d using run-parts (busybox with run-parts is required):
https://www.androidfilehost.com/?fid=23991606952611236
or
Kernel D85520P bumped and with ramdisk implementing init.d without prerequisites:
https://www.androidfilehost.com/?fid=23991606952611243
in addition, our first version of the SEXY 20P rom can be found here (It doesn't contain init.d implementation nor other customisation, it's just the pure stock prerooted 20P with busybox):
Stock EXperience (for) You -- SEXY rom V1
and original 20P kernel just bumped, without any change:
https://www.androidfilehost.com/?fid=23991606952604603
UPDATE 05/30/15:
To satisfy a solicitation made to me (http://forum.xda-developers.com/showpost.php?p=61059947&postcount=4), I made two other versions which include setting permissive SELinux.
Two versions:
One including init.d with run-parts (requires busybox)
The other with no particular prerequisites.
Setting permissive SELinux is made in the ramdisk before init.d.
init-d with run-parts (for busybox users) and set permissive SELlinux:
https://www.androidfilehost.com/?fid=23991606952612236
md5: 2b068d36a0191df5af63eb90461f4297
init.d without particular prerequites and set permissive SELlinux:
https://www.androidfilehost.com/?fid=23991606952612230
md5: 091621d8fc0d1c494f3fd71321c20693
Thank's and credits:
@Chainfire for supersu
@Cloudyfa for his script sh supersu and busybox install and permission to use it.
@thecubed, @autoprime and codefire team pour bump!
@Skin1980 for his live bump @thecubed for his [Tool][python] LG Compressed KDZ Extractor
@cybojenix for his (system merger)
@bullghost for his windows GUI version KDZ and TOT Extractor
@osm0sis for his Android Image Kitchen - Unpack/Repack Kernel Ramdisk [Win/Android/Linux]
Nice work my friend :good:
Nice! Good luck with development. Gonna try the rom when it's ready.
Plz feedback for life battery..tnx
jojobans said:
Plz feedback for life battery..tnx
Click to expand...
Click to collapse
m8, kernel is just released.
No one can give feedback with few hours of use.
you have to fully charge 1 or 2 times for conclusion
jojobans said:
Plz feedback for life battery..tnx
Click to expand...
Click to collapse
Also if you read his posts he said its a stock kernel with init.d support how battery could be different than stock kernel?
About SELinux permissive request:
http://forum.xda-developers.com/showpost.php?p=61058876&postcount=3
OP UPDATED:
To satisfy a solicitation made to me (http://forum.xda-developers.com/showpost.php?p=61059947&postcount=4), I made two other versions which include setting permissive SELinux.
Two versions:
One including init.d with run-parts (requires busybox)
The other with no particular prerequisites.
Setting permissive SELinux is made in the ramdisk before init.d.
init-d with run-parts (for busybox users) and set permissive SELlinux:
https://www.androidfilehost.com/?fid=23991606952612236
md5: 2b068d36a0191df5af63eb90461f4297
init.d without particular prerequites and set permissive SELlinux:
https://www.androidfilehost.com/?fid=23991606952612230
md5: 091621d8fc0d1c494f3fd71321c20693
Thank you... i searched for a Stock Kernel with only init.d support ... keep it up...
Stock kernel with permissive and init.d without any other tweaks..
Thank you, maybe this is what I need
How to install it? Need to flash via ADB?
dantezinn said:
How to install it? Need to flash via ADB?
Click to expand...
Click to collapse
What about reading the op?

[Mini-Howto] Layers Management via Init.d script

Like many of you, I like to keep my Android system rootless and true to stock as much as possible. However, I like to be able to enjoy the native support of layers for better look n feel. I wrote the script attached to help me with it however, it doesn't come easy without root access. There are some work cut out for you, read below.
Prerequisites:
Have extracted theme from layers theme app from Play Store. No, I'm not talking about the main theme app which is used by Layers Manager. Rather, it's the apks that go into the /vendor/overlay. I tried to extract respective apks out of the main one without using Layers Manager. However, my attempts yielded no success as I'm getting FCs all over, so I must be missing something. I current have a Nexus 9 which is rooted with Layers Manager, I use N9 for testing out and bring the /vendor/overlay/*.apk onto my N6P under /sdcard for my script to process. If you know of a better way, by all means share.
Of course, kernel which support INIT.D.
TWRP installed for root access via recovery, a MUST.
Busybox installed via flashable zip
Install:
- Download the script attached
- Rename .txt to .sh
- Have all extracted themed apks in one directory. For instance, I like fa and art layers, so my directory on sdcard as such /sdcard/0flash/layers/fa/fa_*.apk
- Change up the first few lines to match your environment
- Boot into twrp, mount /system if needed
- Drop the script into /system/etc/init.d
- chmod 755 /system/etc/init.d/01layersmanager.sh
- Create a file named ".current_theme" in /sdcard/
- In the above file (.current_theme), put the name of theme you want init.d to install. Example, if I want to install "fa" then I'll just have a line of text fa in it (same goes to art, coalesce,etc). IMPORTANT: no trailing new line.
- Reboot and test it out
- If theme successfully installed, you'll see it.
- Also, the /sdcard/.current_theme file will be updated with "current" to avoid theme installation on next reboot if you don't want to install new themes.
Troubleshoot:
See /sdcard/debug.txt for info. If you want additional information dumped, edit the init.d script to echo out more.
O bio hnki
vboyz103 said:
Like many of you, I like to keep my Android system rootless and true to stock as much as possible. However, I like to be able to enjoy the native support of layers for better look n feel. I wrote the script attached to help me with it however, it doesn't come easy without root access. There are some work cut out for you, read below.
Prerequisites:
Have extracted theme from layers theme app from Play Store. No, I'm not talking about the main theme app which is used by Layers Manager. Rather, it's the apks that go into the /vendor/overlay. I tried to extract respective apks out of the main one without using Layers Manager. However, my attempts yielded no success as I'm getting FCs all over, so I must be missing something. I current have a Nexus 9 which is rooted with Layers Manager, I use N9 for testing out and bring the /vendor/overlay/*.apk onto my N6P under /sdcard for my script to process. If you know of a better way, by all means share.
Of course, kernel which support INIT.D.
TWRP installed for root access via recovery, a MUST.
Busybox installed via flashable zip
Install:
- Download the script attached
- Rename .txt to .sh
- Have all extracted themed apks in one directory. For instance, I like fa and art layers, so my directory on sdcard as such /sdcard/0flash/layers/fa/fa_*.apk
- Change up the first few lines to match your environment
- Boot into twrp, mount /system if needed
- Drop the script into /system/etc/init.d
- chmod 755 /system/etc/init.d/01layersmanager.sh
- Create a file named ".current_theme" in /sdcard/
- In the above file (.current_theme), put the name of theme you want init.d to install. Example, if I want to install "fa" then I'll just have a line of text fa in it (same goes to art, coalesce,etc). IMPORTANT: no trailing new line.
- Reboot and test it out
- If theme successfully installed, you'll see it.
- Also, the /sdcard/.current_theme file will be updated with "current" to avoid theme installation on next reboot if you don't want to install new themes.
Troubleshoot:
See /sdcard/debug.txt for info. If you want additional information dumped, edit the init.d script to echo out more.
Click to expand...
Click to collapse
Yt? Bird :
Sent from my Nexus 6P using XDA-Developers mobile app

Categories

Resources