Last active
August 29, 2015 14:14
-
-
Save frsela/c4e117e5164152afa25d to your computer and use it in GitHub Desktop.
Enable Push traces on a Firefox OS device
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
echo "Enabling PushService traces on your FFOS connected device..." | |
AUXPATH=_____PUSH_____ | |
echo "Getting OMNI.JA..." | |
adb pull /system/b2g/omni.ja . | |
mkdir $AUXPATH | |
cd $AUXPATH | |
unzip ../omni.ja | |
rm ../omni.ja | |
echo "Changing services.push.debug preference into defaults/pref/b2g.js ..." | |
sed -i 's/"services.push.debug", false/"services.push.debug", true/' defaults/pref/b2g.js | |
echo "Generating new OMNI.JA..." | |
zip ../omni.ja -r * | |
cd .. | |
echo "Updating OMNI.JA in the phone..." | |
adb shell stop b2g | |
adb remount | |
adb push omni.ja /system/b2g/omni.ja | |
adb shell ls -l /system/b2g | |
adb shell start b2g | |
rm omni.ja | |
echo "Cleaning..." | |
rm -rf $AUXPATH | |
echo "\o/ Done ! - Now use adb logcat | grep Push to see push traces" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment