Hello Mobile Folks,

It was brought to my attention that some of you don't know how to use the
add-on sdk to make mobile add-ons nor how awesome that can be.  Please
allow me to explain this for a moment, by providing a step by step guide:

1.  Install `jpm` and `jpm-mobile` using `npm`, (ex `npm install jpm -g`)

2.  Create your add-on template with `jpm init` and make sure mark "fennec"
as a supported engine

3. Install awesome modules from npm (want an about:url? block network
requests? or use underscore? get all that power and much more from npmjs.org
)

4.  Build your awesome add-on

5.  Now you can try it out!  Use `jpm-mobile run --adb /path/to/adb` to run
the add-on on your android device with a blank profile

6.  You should probably create tests now, so write some in the `test`
folder created by `jpm init` in step 2.

7.  Now you can run those tests on your android device with `jpm-mobile
test --adb ...` and see the results in stdout

8. Now you should push this code to github, setup travis, and include a
`.travis.yml` file copied from
https://github.com/erikvold/jpm-mobile-travis-example/blob/master/.travis.yml

9. With all of this you can now view your automated tests on travis-ci
which will look like
https://travis-ci.org/erikvold/jpm-mobile-travis-example/builds/58633217

I'm not sure what you do to run/test restartless add-ons on fennec..  I
imagine this is easier though, and by the way `jpm-mobile` works with
restartless add-ons (but you don't get the test infrastructure nor 3rd
party modules from npm).

Regards,

Erik
_______________________________________________
mobile-firefox-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/mobile-firefox-dev

Reply via email to