How to FireFox extension development environment setup.
https://developer.mozilla.org/en-US/Add-ons/Setting_up_extension_development_environment
Basically, you setup another profile.
You then setup that environment for development manually or using an extension that sets those parameters automatically.
Install these two extensions
https://addons.mozilla.org/en-US/firefox/addon/developer-profile/
https://addons.mozilla.org/en-US/firefox/addon/devprefs/
Be sure to read on how to package your extensions.
cd myexample
zip -r ../myexample.xpi *
cd ..
ls *.xpi
For more information see
https://developer.mozilla.org/en-US/Add-ons
Run this command line to start the FireFox profile on OSX, terminal window will display debugging information.
/Applications/Firefox.app/Contents/MacOS/firefox-bin -no-remote -P dev &