Last Comment Bug 708459 - Implement mechanism for selecting which installed Firefox version will be loaded to run natively-installed webapp
: Implement mechanism for selecting which installed Firefox version will be loa...
Product: Firefox Graveyard
Classification: Graveyard
Component: Web Apps (show other bugs)
: Trunk
: All All
: P2 enhancement
: Firefox 14
Assigned To: Dan Walkowski
: Jason Smith [:jsmith]
Depends on:
  Show dependency treegraph
Reported: 2011-12-07 16:14 PST by Michael Hanson
Modified: 2016-02-04 15:00 PST (History)
9 users (show)
jsmith: in‑moztrap-
See Also:
QA Whiteboard:
Iteration: ---
Points: ---


Description Michael Hanson 2011-12-07 16:14:26 PST
Currently, the Mac app launcher always targets the XUL runtime contained in the application with Bundle ID "org.mozilla.firefox".  There is a command-line option (-p) to the foxlauncher which allows the use of a different application, but this doesn't give a great launch experience (no menubar, no Dock icon, etc)

Developers and advanced users would benefit from the ability to target an Aurora or Nightly build of Firefox, so they could use a new feature or API.  It would additionally be useful to target a different build on a per-application basis.

A clean implementation of this would be to place something inside the bundle that contains a "preferred web runtime" field.  This could potentially have a UI to allow users to pick a different runtime.

A short-term fix would be to do something like this: 

When the launcher starts, check whether a FIREFOX_RUNTIME_ID file exists.  

If it does, load it as a string, and append it to "org.mozilla.".  

If an application with that Bundle identifier is found (through NSWorkspace), use that application as the runner; if not, fallback on "org.mozilla.firefox"

We would then advise developers to "Show Package Contents" and create a new file with this name, and place the string "aurora" or "nightly" into it.  Alternatively we could make the file part of our standard .app distribution but make it empty.
Comment 1 Anant Narayanan [:anant] 2011-12-07 16:33:56 PST
This is relevant on Windows too. We should allow apps to target a specific version of Firefox, and hopefully we can do this in a cross-platform manner (eg. putting the FIREFOX_RUNTIME_ID file in XUL/?).
Comment 2 Bill Walker [:bwalker] [@wfwalker] 2011-12-07 17:07:13 PST
marking as P2, not a blocker but do want ASAP.
Comment 3 Jason Smith [:jsmith] 2012-02-11 16:14:43 PST
A Pivotal Tracker story has been created for this Bug:
Comment 4 Tim Abraldes [:TimAbraldes] [:tabraldes] 2012-03-14 13:50:50 PDT
This is still relevant as we move from the extension-based implementation to the m-c-based implementation: Developers will likely want to test their natively-installed apps against multiple versions of Firefox.

On Windows, the version of Firefox that will be loaded is the one whose directory is specified in the natively-installed webapp's "application.ini":



Adding Dan and Myk to weigh in about Mac.
Comment 5 Dan Walkowski 2012-03-14 14:17:22 PDT
I've already implemented and checked in a process for doing this.  It is intended as a developer tool though, and must be changed on a per-app basis.
Comment 6 Myk Melez [:myk] [@mykmelez] 2012-04-25 15:55:40 PDT
As Dan mentions in comment 5, he has implemented a mechanism for doing this on Mac.  And as Tim mentions in comment 4, there's another mechanism for doing it in Windows.  So this seems fixed.  If there are aspects of those mechanisms that are suboptimal, let's open new, targeted bugs on them.
Comment 7 Rob Hawkes [:rob] 2012-04-26 01:16:12 PDT
(In reply to Dan Walkowski from comment #5)
> I've already implemented and checked in a process for doing this.  It is
> intended as a developer tool though, and must be changed on a per-app basis.

Dan, do you mind informing me of this process so I can show app developers how to use it for testing?
Comment 8 Jason Smith [:jsmith] 2012-05-12 08:43:24 PDT
How would I go about verifying this fix? Would this involve changing the application.ini file for a web application to change what firefox version to use?
Comment 9 Myk Melez [:myk] [@mykmelez] 2012-05-17 17:20:01 PDT
Jason: you would edit the Info.plist file for an app, adding a FirefoxBinary key whose value is the ID of an installed Firefox version, f.e. (to specify a debug nightly build):

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "">
<plist version="1.0">

I don't actually know what the valid values of that string are, however.
Comment 10 Jason Smith [:jsmith] 2012-05-17 18:22:35 PDT
Would an end-user ever do what you've described? Sounds like they wouldn't do that, but would like to confirm (trying to figure out if this is worth verifying or not).
Comment 11 Myk Melez [:myk] [@mykmelez] 2012-05-18 10:50:39 PDT
No, a user will never do that.  It's a developer- and tester-facing feature.

Note You need to log in before you can comment on or make changes to this bug.