For Firefox 5 we want to provide users with the option to install developer tools from AMO. For further details please see: http://mozilla.github.com/devtools/2011/install.html
Created attachment 518394 [details] [diff] [review] firefox patch This is the Firefox patch that adds the Install developer tools menuitem.
Assignee: nobody → mihai.sucan
Status: NEW → ASSIGNED
Here's the github repo with the Developer Tools Installer extension: https://github.com/mihaisucan/Mozilla-Developer-Tools-Installer As discussed with Kevin, the extension needs to be restartless / bootstrapped, like our Jetpack addons will be. What I did is a really lightweight extension. I wasn't initially sure to go for Jetpack or just write this as a "pure" XUL extension, but having looked into the docs and more into how Jetpack works, thought it would be a "too heavy" layer to do it in Jetpack - I'd need chrome access anyway. I wanted Jetpack, since it's what we want to use, but err'ed to not use it. Things to note: - the Firefox patch is minimal, in the sense that it only gives us what we need: install the "developer tools installer" extension. As discussed with Kevin, this extension will allow us to customize the user experience as we want. We don't want to use a static list of extensions we install, in Firefox - this extension itself will determine which extensions to install. - the extension can give devs options to switch to beta tools, back to stable tools, and popup information about new features, new tools, etc. - we still want to rely on AMO to deliver updates (obviously), we just want to control what happens, and how new tools are presented to the devs. - due to bugs in how bootstrapped extensions work , the code you see in the extension is pretty "weird". I don't load a XUL overlay, because the changes I do are fairly minimal and the problems with loading XUL overlays are quite many. Please let me know if the solution I use is fine (the window watcher stuff). - remaining work revolves around: * figuring out how to do the channel switching stuff - how do we switch from stable to beta devtools? * Kevin wants us to make sure we don't reinstall devtools the user specifically disabled/removed. If they are disabled, sure, we can avoid doing that, but once you remove a devtool, the code could "think" that's a "new" devtool that needs to be installed. If we really want to avoid reinstalling devtools the user elects to remove, we need to keep track of the list of devtools the user removes. * figure out how we present new stuff. At the moment I elected to simply open a web page on install/upgrade, which would tell the user about new stuff. Kevin seems to want a more elaborate approach.  * check if the current Firefox version is a beta or not. (should be easy) Please let me know if this stuff is on the right track. Also, please point out any problems with the code, changes you want me to make. Thanks!  http://adblockplus.org/blog/how-many-hacks-does-it-take-to-make-your-extension-install-without-a-restart  http://mozilla.github.com/devtools/2011/install.html
Comment on attachment 518394 [details] [diff] [review] firefox patch + labelToBeta="&switchDevToolsToBeta.label;" + labelToStable="&switchDevToolsToStable.label;" what are these attributes used for? They're not valid attributes. I can imagine their purpose based on the names and contents, but how are you planning to use them? I think rather than include these in Firefox UI, it would be better making these prefs. A developer wishing to get onto beta-level tools is probably not going to be put off working in about:config. +const DEVTOOLS_INSTALLER = "https://addons.mozilla.org/firefox/downloads/latest/60/addon-60-latest.xpi?src=addondetail"; what's this? const name should probably have URL in there somewhere. +const MIME_XPI = "application/x-xpinstall"; Do we not have this defined somewhere? I bet Mossop knows a place...
(In reply to comment #3) > Comment on attachment 518394 [details] [diff] [review] > firefox patch > > + labelToBeta="&switchDevToolsToBeta.label;" > + labelToStable="&switchDevToolsToStable.label;" > > what are these attributes used for? They're not valid attributes. I can imagine > their purpose based on the names and contents, but how are you planning to use > them? I am using them in the extension, for localization purposes. > I think rather than include these in Firefox UI, it would be better making > these prefs. A developer wishing to get onto beta-level tools is probably not > going to be put off working in about:config. I can agree to that. Kevin and I discussed it would be nice to have that "Install Developer Tools..." menuitem change to "Switch to Beta Tools..." once the user installs the stable tools. Do you want us to simply remove the menuitem? This would also allow me to remove the switchDevTools labels. > +const DEVTOOLS_INSTALLER = > "https://addons.mozilla.org/firefox/downloads/latest/60/addon-60-latest.xpi?src=addondetail"; > > what's this? const name should probably have URL in there somewhere. This URL is obviously a placeholder. It's the "Web developer" extension by Chris Pederick - I used it to test the code, if the extension installation works. We'll need to point this to our "developer tools installer" extension - it's not yet on AMO, so no link (it's only on github). > +const MIME_XPI = "application/x-xpinstall"; > > Do we not have this defined somewhere? I bet Mossop knows a place... I haven't seen it in browser.js. I added this because it seems browser.js also has other MIME types hard coded in the same way. Please also check the extension code. ;) Thanks for your feedback!
Comment on attachment 518394 [details] [diff] [review] firefox patch Canceling feedback request on this, based on the latest decisions wrt. the future of the developer tools.
Does this bug have a purpose anymore?
(In reply to comment #6) > Does this bug have a purpose anymore? No I think we can WONTFIX it
This bug is done, given that the tools are built-in and not on AMO.
Status: ASSIGNED → RESOLVED
Last Resolved: 7 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.