I am trying to run simple Firefox Add-on (works well on PC) on Android tablet. I have performed all actions described here to set up environment and trying to run
jpm-mobile run --adb "C:\Program Files\Android\android-sdk\platform-tools\adb.exe"
The output is
Running Firefox instance ...
Starting Firefox with /mnt/sdcard/jetpack-profile
--------- beginning of /dev/log/main
Starting: Intent { act=android.activity.MAIN cmp=/mnt/sdcard/jetpack-profile (has extras) }
Error type 3
Error: Activity class {/mnt/sdcard/jetpack-profile} does not exist.
As I understand the cmp= should be org.mozilla.fennec/.App Trying to fix this I found this code in ...\AppData\Roaming\npm\node_modules\jpm-mobile\lib
function amStart(options) {
console.log("Starting Firefox with " + options.profile);
var p = cp.spawn(options.adb, [
"shell",
"am start",
"-a",
"android.activity.MAIN",
"-n",
options.intent + "/.App",
"--es",
"args",
"-profile " + options.profile
], makeOptions(options));
When this lines are removed
"--es",
"args",
"-profile " + options.profile
Firefox Nightly is started but my add-on is not installed.
I also tried to run this
am start -a android.activity.MAIN -n org.mozilla.fennec/.App --es args -profile /mnt/sdcard/jetpack-profile
from adb shell. As the result Firefox is started but add-on is not installed.
The tablet's Android version is 4.2.1
What should I do to get my add-on installed?
This string
"-profile " + options.profile
in C:\Users\UserName\AppData\Roaming\npm\node_modules\jpm-mobile\lib\adb.js on line 74 should be changed to this
"'-profile " + options.profile + "'"
From am command manual:
<INTENT> specifications include these flags and arguments:
...
[-e|--es <EXTRA_KEY> <EXTRA_STRING_VALUE> ...]
As I understand -profile /mnt/sdcard/jetpack-profile is not recognized as <EXTRA_STRING_VALUE>
because of space character.
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments