[Miscellaneous Android Development] heart_crafter:
i use SQLite Database Browser for editing sqlite db files.

copying of other data doesnt work because every data belongs to it's apk... meaning their owner permissions must match... this is why i was looking for chownto command that is chown [ref] [file] normally as you guys suggested :D

so i was thinking to change the permissions this way:

assuming you have the data in /system/backup/data/com.launcherpro/preferences.xml

on first boot we'll have to wait for the program to make the xml file on its own...

then we say if /data/data/com.launcherpro/preferences.xml exist then match the ownership/permissions with /system/backup/data/com.launcherpro/preferences.xml file.

then replace /data/data/com.launcherpro/preferences.xml with /system/backup/data/com.launcherpro/preferences.xml

i confirm this works :P

as you probabaly know all apps have their own owner...

they goes like app_01, app_02...

so setting the permissions using method above can be used if you add or remove many apps while building the rom...

or else you can just set the permissions in the inti script and hard code the ownership/permissions...

have fun :D

see the code i used... but the permissions are hard coded... this code was written before i got to know the chown [ref]

[file] command

#!/system/bin/busybox sh
echo "========== Import Launcher Preferences =========="
if [ ! -e "/system/usr/customize/logs/LauncherPrefLoaded" ];then
log -p I -t boot "Importing Launcher Preferences.."
#toolbox sleep 30
#echo "sleep works"
pm disabled com.fede.launcher
toolbox rm -r /data/data/com.fede.launcher
toolbox mkdir /data/data/com.fede.launcher
toolbox mkdir /data/data/com.fede.launcher/shared_prefs
toolbox mkdir /data/data/com.fede.launcher/files
toolbox mkdir /data/data/com.fede.launcher/databases
toolbox mkdir /data/data/com.fede.launcher/lib
toolbox chown app_13.app_13 /data/data/com.fede.launcher
toolbox chown app_13.app_13 /data/data/com.fede.launcher/shared_prefs
toolbox chown app_13.app_13 /data/data/com.fede.launcher/files
toolbox chown app_13.app_13 /data/data/com.fede.launcher/databases
toolbox chown system.system /data/data/com.fede.launcher/lib
cp -f -r /system/usr/customize/apps_data/com.fede.launcher/shared_prefs/com.fede.launcher_preferences.xml /data/data/com.fede.launcher/shared_prefs/com.fede.launcher_preferences.xml
cp -f -r /system/usr/customize/apps_data/com.fede.launcher/databases/launcher.db /data/data/com.fede.launcher/databases/launcher.db
toolbox chmod 660 /data/data/com.fede.launcher/shared_prefs/com.fede.launcher_preferences.xml
toolbox chmod 660 /data/data/com.fede.launcher/databases/launcher.db
toolbox chown app_13.app_13 /data/data/com.fede.launcher/shared_prefs/com.fede.launcher_preferences.xml
toolbox chown app_13.app_13 /data/data/com.fede.launcher/databases/launcher.db
echo > /system/usr/customize/logs/LauncherPrefLoaded
log -p I -t boot "Launcher Preferences Imported.."
echo "imported"
pm enable com.fede.launcher
fi

you can also use while loop to see file "/data/data/com.fede.launcher/shared_prefs/com.fede.launcher_preferences.xml" exists then execute the script... i i cant find this script atm...

i was planing to release another rom with such coding... but i feel like i dont have much time in my hands :P

laterz!