Save and Restore Hero Desktop Shortcuts using GScript - Updated - G1 Android Development

Thank You firstly to rogro82 for your excellent app, so usefull!!
I dont know about you, but with all the Hero ROM's being posted these days, its become a pain to continually restore my shortcuts to the desktop each time.. I find that Backup for Root users only saves Cupcake/Launcher shortcuts, but not Hero... This goes for ChompSMS also..
I have created 4 simple GScript scripts (Using root) to Save and Restore Hero Home, and ChompSMS Settings when required.
This is what you need to do:
1) Download or have GScript or Gscript Lite installed on your phone
2) Create a folder on your SDCard called GScriptSaves. Your folder structure should now be /SDCard/GScriptSaves
3) Download and rename my 4 scripts to remove the .txt extension, e.g. from Save Hero Home.sh.txt -> Save Hero Home.sh. And place them in the /sdcard/gscripts folder
4) Load the 4 scripts into your gscript/Lite application and save..
Now once you have your desktop as you like it, run "Save Hero Home" from GScript...
Your Desktop should now be saved in the folder called /SDCard/GScriptSaves/com.htc.launcher
Now anytime you install a new Hero Rom, run step 4) and then simply run "Restore Hero Home" from GScript. Then all you need to do is Kill the Home app (TouchFLO/Rosie), I use Taskiller for this.. Open Taskiller, and find the TouchFLO process, then hit the TouchFLO app to kill it.. then press home... Then wait patiently whilst Rosie loads!!
This has worked for me on Casper, Elite Hero and JAC 1.72r2 ROM's.. Haven't tried it on other ROM's.
The same method can be used for the Save Chomp.sh file too... But here you are saving any customisations you make with Chomp (I can not verify as yet if this will save Notify tones and messages also as I haven't tried out a new rom yet!)
The save/restore sh files could also be combined into one file. i.e to create a Save ALL and Restore ALL sh files...

Thanks, but is all that does is save the desktop shortcuts

thanks, great script for flash adicts

shaolinx said:
Thanks, but is all that does is save the desktop shortcuts
Click to expand...
Click to collapse
The RestoreHome.sh will restore your shortcuts on a new Hero ROM, you use it like you would the Backup root program when ever you try out a new rom..
You can test it by deleting a couple of shortcuts then restoring it.. Remember to Kill TouchFlo though and press home..
Its a very simple script, but the same principle could be used to back/restore phone settings, Chomp SMS preferences, Ringtones, etc.. You just add similar entries for the other settings stored within /data/data

dipeshb said:
The RestoreHome.sh will restore your shortcuts on a new Hero ROM, you use it like you would the Backup root program when ever you try out a new rom..
You can test it by deleting a couple of shortcuts then restoring it.. Remember to Kill TouchFlo though and press home..
Its a very simple script, but the same principle could be used to back/restore phone settings, Chomp SMS preferences, Ringtones, etc.. You just add similar entries for the other settings stored within /data/data
Click to expand...
Click to collapse
Where the script save shortcut backup?

fridlack said:
Where the script save shortcut backup?
Click to expand...
Click to collapse
Change StoreHome.sh.txt to StoreHome.sh - This is the save shortcuts script!

SWEET!
Thanks for your work

life saver, thanks
in case anyone's following it step by step (like me) there's no gscripts folder on the SD card
Also, the .sh files don't show up when adding a new scrips it just says ""select a file (.sh from sd card)"
the files are named correctly
EDIT: never mind, after opening the software it created a "gscript" folder (no "s")

Im on JACHero 1.5r2 and get an error, I followed everything to a T
I have HeroHome on the root of my sd
Removed the .txt from both scripts
Placed scripts in gscript
See attachement

Nice, thanks a lot.
Works for all your scenes, too.

Lakers3408 said:
Im on JACHero 1.5r2 and get an error, I followed everything to a T
I have HeroHome on the root of my sd
Removed the .txt from both scripts
Placed scripts in gscript
See attachement
Click to expand...
Click to collapse
on elite hero same here

Lakers3408 said:
Im on JACHero 1.5r2 and get an error, I followed everything to a T
I have HeroHome on the root of my sd
Removed the .txt from both scripts
Placed scripts in gscript
See attachement
Click to expand...
Click to collapse
My bad.. you will need to manually create the com.htc.launcher folder under the HeroHome directory. i.e your folder structure should be :
/sdcard/HeroHome/com.htc.launcher

Nice Idee Can you make more of such Scripts?

Rey-619 said:
Nice Idee Can you make more of such Scripts?
Click to expand...
Click to collapse
Yes.. This is just a basic start that can bee easily added to.. .. I hope to add backups/restores for all settings, Chomp SMS, wallpaper, lock screens etc... Also I would like to auto create the necessary folders rather than having to manually create them. My scripting skills for linux are very limited compared to the other devs here, but no harm in studying up!

modify this:
cp -r /data/data/com.htc.launcher/* sdcard/HeroHome/com.htc.launcher
to
mkdir /sdcard/HeroHome
cp -r /data/data/com.htc.launcher /sdcard/HeroHome
and it'll create folders automatically

blackgin said:
modify this:
cp -r /data/data/com.htc.launcher/* sdcard/HeroHome/com.htc.launcher
to
mkdir /sdcard/HeroHome
cp -r /data/data/com.htc.launcher /sdcard/HeroHome
and it'll create folders automatically
Click to expand...
Click to collapse
Appreciated! Will modify the first post..

looks better ore not?
Code:
echo "Creating backup folder plz wait..."
mkdir /sdcard/HeroHome
echo "Done"
echo "Copy files"
cp -r /data/data/com.htc.launcher sdcard/HeroHome
echo "Done"
Code:
echo "Restore files :) plz wait..."
cp -r sdcard/HeroHome/com.htc.launcher/* /data/data/com.htc.launcher
echo "Done"

Rey-619 said:
Nice Idee Can you make more of such Scripts?
Click to expand...
Click to collapse
you will find some more backup scripts in this thread

I thought it worked, all the widgets and icons showed up then...
BAM!
TouchFLO force close over and over and over and over again
Time to wipe ext

Lakers3408 said:
I thought it worked, all the widgets and icons showed up then...
BAM!
TouchFLO force close over and over and over and over again
Time to wipe ext
Click to expand...
Click to collapse
Hmmmm, sorry to hear that dude.. this has not happened to me, and I'm using the latest rom by JAC. All that comes to mind is that you had widgets on your desktop that a particular version of hero does not support, I.e. the framework is not present. E.g. some hero roms will not support the MT pdf viewer.
This is a rude, crude way of backing up your desktop, but has worked so far from me.. any devs out there who can clean this issue up would be appreciated..

Related

How to Change Music Widget in any Cupcake Build

Always perform a nandroid backup before attempting any mods.
This is a tutorial on how to change the music widget to the one of your liking. It doesn't matter if you have the Dude build and want the G build widget or have the G build and want the 1.5Hr1 widget. This will work for any cupcake (Android 1.5) user who is not happy with their current music widget. I use a windows PC and I am not a Linux guru so I'm not going to attempt to tweak my tutorial for Linux users. Hopefully it's not to hard for them to figure it out from this. (I think it's just file path differences, maybe?)
First step is to have ADB commands working on your computer. Follow this link if you don't know how to do this.
http://forum.xda-developers.com/showthread.php?t=502010
Now that you have ADB, you have to download the appropriate music player/widget that you prefer.
This one is for installing the dark blue music widget with the off-center play/pause button and the transparent record and needle logo. My personal favorite for looks, but has a play/pause with a easy to miss touch area.
http://rapidshare.com/files/227653807/Music_fancy_widget_G_build.apk
This one is for installing the plain white and pale blue music widget with rectangular shape and the large play/pause button with it's large touch area.
http://rapidshare.com/files/227653907/Music_standard_build.apk
This third option is for future development. You can "harvest" a third music widget/player from a third source that doesn't yet exist using the ADB pull command. Lets say your using build X, but build Y has a theme available and you love the themed music widget on themed build Y. What you do is perform a nandroid backup of your current build so you can return to it later and install build Y and then theme it. (Don't waist your time setting up your settings because you won't be on this build for long. Just make sure USB debugging is enabled in settings > Applications > Development so you can use ADB.) You can skip this step if you have access to a friends phone who's already running the music player/widget you want. Connect the USB cable to the phone and go into where you run your ADB commands in Command Prompt on your PC. Type in this command.
adb pull system/app/Music.apk c:\your_path_here
Click to expand...
Click to collapse
The "system/app/Music.apk" part of the command is case sensitive. This will create the Music.apk with the widget you want at the path you specify. Next you can use Fastboot to restore your nandroid backup of build X. (Nandroid saves everything. It's as if you never left.)
Next step is to rename the downloaded file "Music.apk". It's case sensitive and take note of the folder path it's in.
Next, enter the following ADB commands from the appropriate place in Command Prompt. (Start > Run > type "cmd")
adb remount
adb shell rm -r system/app/Music.apk
adb push c:\your_path_here\Music.apk system/app
Click to expand...
Click to collapse
"system/app/Music.apk" and "system/app" parts are both case sensitive.
saying no such directory, would apps to sd card cause that, and ifso what would i instead need to put in?
i never knew there was a difference between the music widgets...
whats different about them?
the gui??
pgiuoco said:
saying no such directory, would apps to sd card cause that, and ifso what would i instead need to put in?
Click to expand...
Click to collapse
On the last step, adb push, dont just put your directory, put in the file name also, Music.apk. For example, i put the file on my C directory to make it easy, so I typed "adb push c:\Music.apk system/app" without the "".
FYI - I have Apps2SD and I used the above command. Guess that doesn't make a difference, assuming because the symlinks say so? I'm such a Linux noob!!!!
bigballa said:
i never knew there was a difference between the music widgets...
whats different about them?
the gui??
Click to expand...
Click to collapse
Yes, different looking gui, the Dark Blue is very nice!
P.S. Nice write up!
setzer715 said:
On the last step, adb push, dont just put your directory, put in the file name also, Music.apk. For example, i put the file on my C directory to make it easy, so I typed "adb push c:\Music.apk system/app" without the "".
Click to expand...
Click to collapse
Wow, that was a BIG OOPS! Thanks for catching that. I fixed the original post.
Has anyone found a way to do this via Terminal Emulator? I'm at work so I wanna do this now instead of waiting till I get home.
djdeviance said:
Has anyone found a way to do this via Terminal Emulator? I'm at work so I wanna do this now instead of waiting till I get home.
Click to expand...
Click to collapse
I'm not a frequent Linux user, but I know a couple of commands. You could download the apk file to your sdcard and try this. This method is not recommended!
su
rm -r system/app/Music.apk
Click to expand...
Click to collapse
This will delete your old music player. Next, you can just install the new music player apk through Apps Installer or whatever you use in it's place. This will allow you to use the new music player as if it was any other 3rd party app. However, I recommend uninstalling it and doing it through the ADB push when you get home.
yeah the app installer method didn't work for me
pgiuoco said:
yeah the app installer method didn't work for me
Click to expand...
Click to collapse
Did you delete the original Music.apk first? Do you have cupcake, or are you using JF RC33 like it says in your sig? This music player has a widget embedded and needs cupcake. If neither of these is the problem, then just use the adb push commands in the first post. I don't recommend using apk installer. I just posted that to help out someone who was too impatient to get home to his pc.
testing567 said:
Did you delete the original Music.apk first? Do you have cupcake, or are you using JF RC33 like it says in your sig? This music player has a widget embedded and needs cupcake. If neither of these is the problem, then just use the adb push commands in the first post. I don't recommend using apk installer. I just posted that to help out someone who was too impatient to get home to his pc.
Click to expand...
Click to collapse
Haha ended up doing it at home anyways. =D Yeah i was kinda doing nothing at work. So as usual I started fidgeting with my phone.
the steps given in the first post work perfectly...!!!
i am on ADP1.5H A2SD...Gud Work...THNX..!!
If someone could post screenshots of the different UIs, that'd be great.
For some reason, when I pushed the Music.apk it worked fine, but when I tried to do the same thing with the CalendarProvider.apk, it didn't....
This method works for me as well. How do you take screenshots with the new builds?
CalendarProvider.apk... Just do a normal .apk installation.
Does this only work for Rooted phones as when I try it I get permission denied
Code:
C:\android\tools>adb shell rm -r system/app/Music.apk
rm failed for system/app/Music.apk, Read-only file system
C:\android\tools>adb shell
$ su
su
su: permission denied
$
jayaustn said:
If someone could post screenshots of the different UIs, that'd be great.
Click to expand...
Click to collapse
i second this idea
moosefist said:
i second this idea
Click to expand...
Click to collapse
I third it
music.apk
can someone post some different download links for the two different music.apk builds? rapidshare has always hated me and will still not let me download either of them saying that my ip address is already downloading something. thanks.
Can someone post pics of all the music widgets in order to compare them?

Script to remove apks easily when a new ROM is out

I hate having to remove apps everytime I flash a new ROM. So here is what I've done and I'm sure others too.
1) Open notepad in Windows.
2) Add these lines in it:
adb remount
adb shell rm system/app/*Stock*
adb shell rm system/app/IM.apk
adb shell rm system/app/*Facebook*
adb shell rm system/app/Flickr.apk
adb shell rm system/app/Mail.apk
adb shell rm system/app/htcmailwidgets.apk
adb shell rm system/app/Sprint_Navigation.apk
adb shell rm system/app/Sprint_NFL.apk
adb shell rm system/app/Sprint_Nscar.apk
adb shell rm system/app/HTCNew.apk
3) Save it as RemoveAPK.bat on desktop.
4) Double click this file to run it. (This will only work if SDK tools directory is in system path)
If SDK tools is not in your system path, you can place this script in the SDK tools folder and double click in there.
so now anytime a new ROM comes out, connect your phone, and double click. They'll be removed in literally a blink of an eye.
I'd attach this to the thread, but *.bat files are not allowed as attachments.
another suggestion that's awesome too (thanks to daryelv):
daryelv said:
Why not just create your own update.zip to do all the actions after flashing the ROM zip? Here's an example of mine...
Code:
show_progress 0.1 0
delete_recursive DATA:dalvik-cache/
delete_recursive DATA:boot-cache/
delete SYSTEM:app/com.android.launcher2.apk
delete SYSTEM:app/LiveWallpapers.apk
delete SYSTEM:app/LiveWallpapersPicker.apk
delete SYSTEM:app/VisualizationWallpapers.apk
delete SYSTEM:app/HtcLockScreen.apk
delete SYSTEM:app/HtcLockScreen.odex
delete SYSTEM:app/DeskClock.apk
delete SYSTEM:app/DeskClock.odex
delete SYSTEM:app/com.htc.StockWidget.apk
delete SYSTEM:app/Stock.apk
delete SYSTEM:app/Sprint_Navigation.apk
delete SYSTEM:app/HtcFootprintsWidget.apk
delete SYSTEM:app/HtcFootprints.apk
delete SYSTEM:app/LatinIME.apk
delete SYSTEM:app/GSD.apk
delete SYSTEM:app/FieldTest.apk
delete SYSTEM:app/amazonmp3.apk
delete SYSTEM:customize/resource/BigBen.jpg
delete SYSTEM:customize/resource/Colosseum.jpg
delete SYSTEM:customize/resource/EiffelTower.jpg
delete SYSTEM:customize/resource/StatueOfLiberty.jpg
delete SYSTEM:customize/resource/htc_wallpaper_01_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_02_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_03_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_04_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_05_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_06_lockscreen.jpg
delete_recursive SYSTEM:media/audio/
delete_recursive SYSTEM:media/bootscreen/
delete SYSTEM:media/bootanimation.zip
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 10
Just find an existing update package (any of them) and modify the update script to your liking and also put files in /system/ that you want in your ROM. (You could also put files into /data/app/ to load your programs, but I use A2SD which needs to be mounted first).
This also inserts my favorite Boot animation and favorite HTC keyboard into the ROM. My media files I keep in the /sdcard/ directory, so I just delete them from the ROM as well.
The benefits of doing this is that I can leave this on the root of my sdcard and just flash this ZIP after flashing a ROM.
-Daryel
Click to expand...
Click to collapse
Good idea! I never thought of using a bat...I just had a text file I copy and past the commands I use alot...this will save me some time!
great idea. me personally I use the autosign.bat and just unzip the rom remove all the stuff I dont want, add all my tweeks and customizations in and then resign it before I flash it but that becuase I have stuff I add in so thats the easiest way for me to do it. plus then all my stuff is there right at boot.
wtphoto said:
great idea. me personally I use the autosign.bat and just unzip the rom remove all the stuff I dont want, add all my tweeks and customizations in and then resign it before I flash it but that becuase I have stuff I add in so thats the easiest way for me to do it. plus then all my stuff is there right at boot.
Click to expand...
Click to collapse
Yeah. but then you have to unzip. That's too many clicks for me lol. I like the signing part though. You know what you can do. You can probably modify a script to do all that for you.
for instance not worry about modifying a zip, but after it's installed, just run a script that would remove apks, add your themes and apks that you'd want. So you dont have to unzip and re-sign. Unless you end up re-releasing your ROMs to others.
Bat and Cmd files are AMAZING things. Everyone touts VBScript like its a god send, but good ole Bat never fails me.
wtphoto said:
great idea. me personally I use the autosign.bat and just unzip the rom remove all the stuff I dont want, add all my tweeks and customizations in and then resign it before I flash it but that becuase I have stuff I add in so thats the easiest way for me to do it. plus then all my stuff is there right at boot.
Click to expand...
Click to collapse
jackal424 said:
Yeah. but then you have to unzip. That's too many clicks for me lol. I like the signing part though. You know what you can do. You can probably modify a script to do all that for you.
for instance not worry about modifying a zip, but after it's installed, just run a script that would remove apks, add your themes and apks that you'd want. So you dont have to unzip and re-sign. Unless you end up re-releasing your ROMs to others.
Click to expand...
Click to collapse
you could write a batch with a menu system to give various options.
I used to write those all the time until I switched to VB and added graphics.
What does the "HTCNew.apk" contain?
jackal424 said:
Yeah. but then you have to unzip. That's too many clicks for me lol. I like the signing part though. You know what you can do. You can probably modify a script to do all that for you.
for instance not worry about modifying a zip, but after it's installed, just run a script that would remove apks, add your themes and apks that you'd want. So you dont have to unzip and re-sign. Unless you end up re-releasing your ROMs to others.
Click to expand...
Click to collapse
I dont plan on releasing any roms anytime soon since everything I do is theme stuff but by doing that way makes it a lot easier if I fubar something bad with a new mod becuase then I just reflash with the base that I know is good. that and I do it so much it only takes me a bout 1.5 minutes to unzip remove the stuff I dont and drag everything in then resign.
wtphoto said:
I dont plan on releasing any roms anytime soon since everything I do is theme stuff but by doing that way makes it a lot easier if I fubar something bad with a new mod becuase then I just reflash with the base that I know is good. that and I do it so much it only takes me a bout 1.5 minutes to unzip remove the stuff I dont and drag everything in then resign.
Click to expand...
Click to collapse
makes sense...
Hmm. I'm with wtphoto on this one, but I can certainly think of other applications for this. I've never messed with this kinda stuff before. Quick couple of questions:
1. If sdk is in my system path, does that mean I wouldn't need to move stuff to the tools folder to resign it, push it etc?
If so:
2. How do I do this black magic?
I know, I know my inner n00b is showing again
tejasrichard said:
Hmm. I'm with wtphoto on this one, but I can certainly think of other applications for this. I've never messed with this kinda stuff before. Quick couple of questions:
1. If sdk is in my system path, does that mean I wouldn't need to move stuff to the tools folder to resign it, push it etc?
If so:
2. How do I do this black magic?
I know, I know my inner n00b is showing again
Click to expand...
Click to collapse
if sdk tools directory is in your system path, that means any app in that directory can be called from anywhere in your computer, including push.
The directions are in the first post for auto remove script if you need.
Or you can purchase Root Manager for a dollar and remove the apps that way..
@jackal424:
Good to know! Now I just need to figure out how to put sdk in the system path. I'll Google it later.
Why not just create your own update.zip to do all the actions after flashing the ROM zip? Here's an example of mine...
Code:
show_progress 0.1 0
delete_recursive DATA:dalvik-cache/
delete_recursive DATA:boot-cache/
delete SYSTEM:app/com.android.launcher2.apk
delete SYSTEM:app/LiveWallpapers.apk
delete SYSTEM:app/LiveWallpapersPicker.apk
delete SYSTEM:app/VisualizationWallpapers.apk
delete SYSTEM:app/HtcLockScreen.apk
delete SYSTEM:app/HtcLockScreen.odex
delete SYSTEM:app/DeskClock.apk
delete SYSTEM:app/DeskClock.odex
delete SYSTEM:app/com.htc.StockWidget.apk
delete SYSTEM:app/Stock.apk
delete SYSTEM:app/Sprint_Navigation.apk
delete SYSTEM:app/HtcFootprintsWidget.apk
delete SYSTEM:app/HtcFootprints.apk
delete SYSTEM:app/LatinIME.apk
delete SYSTEM:app/GSD.apk
delete SYSTEM:app/FieldTest.apk
delete SYSTEM:app/amazonmp3.apk
delete SYSTEM:customize/resource/BigBen.jpg
delete SYSTEM:customize/resource/Colosseum.jpg
delete SYSTEM:customize/resource/EiffelTower.jpg
delete SYSTEM:customize/resource/StatueOfLiberty.jpg
delete SYSTEM:customize/resource/htc_wallpaper_01_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_02_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_03_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_04_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_05_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_06_lockscreen.jpg
delete_recursive SYSTEM:media/audio/
delete_recursive SYSTEM:media/bootscreen/
delete SYSTEM:media/bootanimation.zip
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 10
Just find an existing update package (any of them) and modify the update script to your liking and also put files in /system/ that you want in your ROM. (You could also put files into /data/app/ to load your programs, but I use A2SD which needs to be mounted first).
This also inserts my favorite Boot animation and favorite HTC keyboard into the ROM. My media files I keep in the /sdcard/ directory, so I just delete them from the ROM as well.
The benefits of doing this is that I can leave this on the root of my sdcard and just flash this ZIP after flashing a ROM.
-Daryel
daryelv said:
Why not just create your own update.zip to do all the actions after flashing the ROM zip?
Click to expand...
Click to collapse
Both methods are great (Update.zip is method I use). Not to mention, with this method, you don't have to be on a computer to do it. Just write the update file once, always leave it on your SD Card and run whenever you want... that's convenient to me.
Plus both files can be distributed to someone whose not tech savvy to wipe what they don't want... thank god!
4SidedDie said:
Or you can purchase Root Manager for a dollar and remove the apps that way..
Click to expand...
Click to collapse
Not saying Root Manager isn't a good purchase, but a .bat file will remove all the apps I want gone faster than any other method I've found. Just double-click and they're all gone!
4SidedDie said:
Or you can purchase Root Manager for a dollar and remove the apps that way..
Click to expand...
Click to collapse
Well... personally, there's no need to pay for something if you're capable of doing it yourself (Not saying you aren't) -- especially when this method is more streamlined and a lot more efficient.
daryelv said:
Why not just create your own update.zip to do all the actions after flashing the ROM zip? Here's an example of mine...
Code:
show_progress 0.1 0
delete_recursive DATA:dalvik-cache/
delete_recursive DATA:boot-cache/
delete SYSTEM:app/com.android.launcher2.apk
delete SYSTEM:app/LiveWallpapers.apk
delete SYSTEM:app/LiveWallpapersPicker.apk
delete SYSTEM:app/VisualizationWallpapers.apk
delete SYSTEM:app/HtcLockScreen.apk
delete SYSTEM:app/HtcLockScreen.odex
delete SYSTEM:app/DeskClock.apk
delete SYSTEM:app/DeskClock.odex
delete SYSTEM:app/com.htc.StockWidget.apk
delete SYSTEM:app/Stock.apk
delete SYSTEM:app/Sprint_Navigation.apk
delete SYSTEM:app/HtcFootprintsWidget.apk
delete SYSTEM:app/HtcFootprints.apk
delete SYSTEM:app/LatinIME.apk
delete SYSTEM:app/GSD.apk
delete SYSTEM:app/FieldTest.apk
delete SYSTEM:app/amazonmp3.apk
delete SYSTEM:customize/resource/BigBen.jpg
delete SYSTEM:customize/resource/Colosseum.jpg
delete SYSTEM:customize/resource/EiffelTower.jpg
delete SYSTEM:customize/resource/StatueOfLiberty.jpg
delete SYSTEM:customize/resource/htc_wallpaper_01_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_02_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_03_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_04_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_05_lockscreen.jpg
delete SYSTEM:customize/resource/htc_wallpaper_06_lockscreen.jpg
delete_recursive SYSTEM:media/audio/
delete_recursive SYSTEM:media/bootscreen/
delete SYSTEM:media/bootanimation.zip
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 10
Just find an existing update package (any of them) and modify the update script to your liking and also put files in /system/ that you want in your ROM. (You could also put files into /data/app/ to load your programs, but I use A2SD which needs to be mounted first).
This also inserts my favorite Boot animation and favorite HTC keyboard into the ROM. My media files I keep in the /sdcard/ directory, so I just delete them from the ROM as well.
The benefits of doing this is that I can leave this on the root of my sdcard and just flash this ZIP after flashing a ROM.
-Daryel
Click to expand...
Click to collapse
uhhh....that's nice...i'm going to give this a shot....it is more convinient then double clicking....it stays on the phone too.... no need to connect phone to comp..
jackal424 said:
uhhh....that's nice...i'm going to give this a shot....it is more convinient then double clicking....it stays on the phone too.... no need to connect phone to comp..
Click to expand...
Click to collapse
Agreed. That is nice.
Nice thread....
Nice thread....
//forum.xda-developers.com/showthread.php?t=581635

Root Explorer not copying

Hi,
I tried to copy an API to /system/app, but when I did that, the screen just blinks, and the file is not pasted into the directory.
I had temp root, and had remounted R/W.
I eventually was able to do the copy by using ES Explorer, but not with RE itself.
Does anyone have any idea what might be wrong?
Thanks,
Jim
Don't know if this helps but... I recently tried to do some copying of files using AndRootFile, and RootExplorer. And like you they did not "take". I finally figured out that after I selected a file to copy, I would use the back arrow button to move to the target folder. This was the problem. When I used the Parent folder icon instead to move back out of the folder, and move to the destination folder without using the back arrow button. the file copied just fine. Hope this helps.
Reggie,
Thanks for the suggestion, but, no, I wasn't using the "back" to get to the /system/app directory. I was clicking on the parent dir, etc.
Jim
I also am having that problem. I tried both the back buttons and the parent directory. Ive tried factor data reset as well. I wander if it has anything to do with the update yesterday?
Until we/someone figures why, you can use root explorer to mount, then the built in es explorer to do the copy...
Jim
I've been doing some stuff w/command line, and I noticed that my stock Gtab doesn't have a native 'cp' command, so you have to use 'busybox cp' instead. I wonder if that's why the RE copy/paste doesn't work?
Jim
SOLVED - it was no native 'cp'
jimcpl said:
I've been doing some stuff w/command line, and I noticed that my stock Gtab doesn't have a native Cp command, so you have to use 'busybox cop's instead. I wonder if that's why the RE copynpasre doesn't work?
Jim
Click to expand...
Click to collapse
Hi,
I just tried a test, where I created a softlink for 'busybox cp':
ln -s /system/bin/busybox /sbin/cp
I then was able to use RE to copy/paste into /system/app !
CAVEAT: I don't know if busybox is on Gtab by default...
Jim
At the command line us cp vs Cp. If you want to copy an entire directory, use cp -R /indirectory /outdirectory .
NMCBR600 said:
At the command line us cp vs Cp. If you want to copy an entire directory, use cp -R /indirectory /outdirectory .
Click to expand...
Click to collapse
Hi,
That was a typo on my part. The 'cp' command (lowercase c) was really missing in my Gtab .
I've been experimenting w/alternate keyboards, and keep making typos ...
Jim
P.S. I fixed the typos ...
jimcpl,
I was just working on putting Market onto my stock machine and I am having the exact same problem. So far as I can see I have set it up right and followed procedure -- but files just won't move.
Now that I have read y'all's comments, I will try again a time or two.
Rev
butchconner said:
jimcpl,
I was just working on putting Market onto my stock machine and I am having the exact same problem. So far as I can see I have set it up right and followed procedure -- but files just won't move.
Now that I have read y'all's comments, I will try again a time or two.
Rev
Click to expand...
Click to collapse
Hi,
BTW, to create the softlink (using ln), you'll need to use adb shell. Or, you could use a terminal, if one's installed (kind of catch 22, since you'd need market to get a terminal).
Otherwise, what might work is:
- z4root to get root
- root explorer to make /system R/W
- kill then restart es file explorer and use that to copy the apks to /system/app
Jim
SIGH ... softlink doesn't survive a reboot
It looks like the softlink that I created disappears after a reboot... then RE can't copy again.
Sorry...
Jim

[HOWTO] MANUALLY save/backup apps and games and more importantly their PROGRESS

Well I browsed through all the forums and I could not find anything that I am going to explain. There are some tits-bits here and there, but I hope this proves to be useful.
I will also explain if you have a xrecovery backup, then how to extract your games and progress from there.
Many of you might be switching ROMs very frequently or upgrading/downgrading their Android. While doing this, we lose all our apps and games and more importanly the game's PROGRESS, if we do not save them.
There are apps available to save apps/games and progress but there is a way to do all these thing MANUALLY. This for those who want the control in their hands , like me.
PART A:
Here's how you do:
1) Create a backup folder on the sdcard with a name that you like. eg. mybackup
1) from your filemanager or from the shell, browse to the directory /data/app and do ls -l. You will get a list of apps which you have installed.
2) Select the app that you want to save/backup and move it to sdcard folder that you have created. The names here would be long but it will be almost similar to the name you see in the UI.
For eg.
Code:
cp uk.co.aifactory.moveitfree.apk /sdcard/mybackup
. would be the command to backup Move It game.
3) Now go to the the directory /data/data and do a ls -l. browse through the list and find a directory which matches the name of the apk without the .apk extension.
for Eg. for the 'move it' game, you will find a directory uk.co.aifactory.moveitfree
Move this directory to the backup folder
Code:
cp -r uk.co.aifactory.moveitfree /sdcard/mybackup
.
For those working on shell, remember to do cp "-r" as you are copying a directory.
You are done!!. You have backed up your app and all the progress related to that app.
Now you can copy mybackup folder to your PC or keep it in the sdcard if you have enough space. Its your choice...
PART B:
How to get the progress and games back after flashing the ROM or after wipeout.
Its easy. Just reverse the steps mentioned above.
1) copy the .apk file from your backup folder to /data/app through filemanager or shell.
Eg.
Code:
cp /sdcard/mybackup/uk.co.aifactory.moveitfree.apk /data/app
2) copy the data directory to the location /data/data.
Eg.
Code:
cp -r /sdcard/mybackup/uk.co.aifactory.moveitfree /data/data
You are back to business, just browse through your apps and enjoy the games from where you left.
UPDATE :
For Angry Birds, when you are done with the above steps, delete the file
/data/data/com.rovio.angrybirdsrio/files/settings.lua
It app will not open up if you dont do it.
-----------------------------------------------------------------------------------------------------------------
Those who have already backedup their ROMs and not saved their apps as mentioned above, dont worry, I have a solution for that too. I am specifically going to explain the method to get it from xrecovery backup.
When you backup your ROM or system using xRecovery, it stores all the data inside /sdcard/xrecovery/backup/<date>.
Inside that folder, there are 3 img files.
cache.img
system.img
data.img
data.img contains all the data/app/games that you had installed, while system.img contains everything that came bundled with ROM. It might differ a bit per devices, but mostly its data.img
I tried to open this file ".img" with a lot of extraction tools but none could help. Atlast, i got help from our great <zdzihu>, and he said, he saves the archive with yaffs2 compression.
There is an app "unyaffs2" which you can use to extract the contents of the archive. Get it from here http://forum.xda-developers.com/showthread.php?t=910255
This app will extract the contents to the folder where you ask it to. Once you have your data, repeat the above mentioned steps to get your apps and games running!!
Thank you for the how to
it not change owner
this is very big problem
Hi dateno1, can you be more specific?
What app are you trying on
What method u used to copy
What error r u getting exactly
Which device and on which step
Sent from my X10mini using XDA App
ronaksv said:
PART B:
How to get the progress and games back after flashing the ROM or after wipeout.
Its easy. Just reverse the steps mentioned above.
1) copy the .apk file from your backup folder to /data/app through filemanager or shell.
2) copy the data directory to the location /data/data.
You are back to business, just browse through your apps and enjoy the games from where you left.
Click to expand...
Click to collapse
i have question on the process of getting it back.
on step 1 you said copy.
is it also ok if you are going to reinstall it then proceed to step 2.
thanks.

[shell][utility][terminal] munky-tool

***MUNKY-TOOL***
IS AN ONBOARD ANDROID UTILITY
FEATURES
[*]Copy system.img
[*]Copy boot.img
[*]Backup efs
[*]Logcat
[*]Backup and Restore Contacts
[*]Out For A Rip
Munky-tool will locate and copy most partitions without you having to track down paths. This is convenient if you use a ROM kitchen, or just want to make a backup of your system without using custom recovery. Some devices do have weird partition names, and munky-tool will not find them. If this happens to you, run the following command in terminal emulator
Code:
ls /dev/block/platform/*/by-name
Paste the output and your device name in the comments, and I will work your device in if possible.
INSTRUCTIONS
Download zip or clone git
Place extracted munky-tool folder in system partition (must be able to set permissions)
Set permissions of munky-tool script (not the directory) to at least 775 (rwx rwx rw)
Open terminal emulator and key in 'su' for root permissions
cd to the munky-tool directory
Type ./munky-tool to execute the script and start the utility
​
DOWNLOAD
github
Dude once again you're creativity and hard work is paying off. Great job man
Style point for the rip bud!
Sounds very helpfull and as markbencze already replyed I gues it's working on the O+O too. Have to try it in the next days.
thx markbencze for sharing.
SaschaKH said:
Sounds very helpfull and as markbencze already replyed I gues it's working on the O+O too. Have to try it in the next days.
thx markbencze for sharing.
Click to expand...
Click to collapse
Yes. I tested it on my OPO. It went out for a rip. It will run on any device, and it will find the partitions on most.
Where's the download link dude, i'm not find download link from github ?
itsnie said:
Where's the download link dude, i'm not find download link from github ?
Click to expand...
Click to collapse
On the right side of page near the clone url, there should be a button that says download as zip.
Just realized you have to be in desktop view to see the download as zip button. I will post an additional link a little later.
Just added backup and restore contacts.
N-i-c-e!
Thank you.
I've been working on the same sort of thing, and trying to figure out how to get adb connected to the phone with debugging off, for those people (I won't use the word I'm thinking of) who don't make backups, then break the screen, or bootloop the phone. Your script makes finding the data partition trivial, but I'm still working on the "force debugging on from outside" part.
But munky is going to be part of my phone from now on.
Rukbat said:
N-i-c-e!
Thank you.
I've been working on the same sort of thing, and trying to figure out how to get adb connected to the phone with debugging off, for those people (I won't use the word I'm thinking of) who don't make backups, then break the screen, or bootloop the phone. Your script makes finding the data partition trivial, but I'm still working on the "force debugging on from outside" part.
But munky is going to be part of my phone from now on.
Click to expand...
Click to collapse
Thanks, man. Glad to hear you like it.
mike the inkman said:
***MUNKY-TOOL***
IS AN ONBOARD ANDROID UTILITY
FEATURES
[*]Copy system.img
[*]Copy boot.img
[*]Backup efs
[*]Logcat
[*]Backup and Restore Contacts
[*]Out For A Rip
Munky-tool will locate and copy most partitions without you having to track down paths. This is convenient if you use a ROM kitchen, or just want to make a backup of your system without using custom recovery. Some devices do have weird partition names, and munky-tool will not find them. If this happens to you, run the following command in terminal emulator
Code:
ls /dev/block/platform/*/by-name
Paste the output and your device name in the comments, and I will work your device in if possible.
INSTRUCTIONS
Download zip or clone git
Place extracted munky-tool folder in system partition (must be able to set permissions)
Set permissions of munky-tool script (not the directory) to at least 775 (rwx rwx rw)
Open terminal emulator and key in 'su' for root permissions
cd to the munky-tool directory
Type ./munky-tool to execute the script and start the utility
​
DOWNLOAD
github
Click to expand...
Click to collapse
Good Tool, do you already plan to support restore EFS? which make a full loop of running time change the EFS setting without a PC,
this can help to me to control the modem band preset selections for network testing purpose.
Azlun said:
Good Tool, do you already plan to support restore EFS? which make a full loop of running time change the EFS setting without a PC,
this can help to me to control the modem band preset selections for network testing purpose.
Click to expand...
Click to collapse
It is usually done in bootloader, but I am pretty sure I can make it work. Just need to test it before I release it. I am also going to release this as an apk soon. (Don't know how soon, but I probably won't have time for a few weeks)
An app that we can point new users to that will back up their userdata partition? Fantastic!
Rukbat said:
An app that we can point new users to that will back up their userdata partition? Fantastic!
Click to expand...
Click to collapse
Yeah, I think it will fill a need. I am going to do an APK to do the things from this script, and a corresponding GUI Linux package for APK modding, and maybe do something for Windows as I get time. In the process of moving somewhat unexpectedly, so it is taking longer than I would have liked.

Categories

Resources