Open multiple firefox instances with different profiles on Mac OS X - macos

What is the best way to open different firefox instances (firefox 3 to 10) with different profiles (on 10.5, 10.6 and 10.7)?
With versions prior to Firefox-7, modifying the content of the firefox package and adding -no-remote -P {PROFILE} worked.
However, with the latest versions of firefox it's not working.
I've also tried with Automator without success.
Has anyone faced a similar problem and fixed it?
Thanks

For new versions of Firefox use the following command:
/Applications/Firefox.app/Contents/MacOS/firefox-bin -P -no-remote &> /dev/null &
source: http://sonnygill.net/mac/mac-multiple-firefox-profiles/
On page explains how to use Automator to create a shortcut.

#dalvan answer does not work any more (10.15)
Workaround I've found is:
run first firefox instance as normal (profile chooser window opens, select primary profile)
use an Automator.app or run from shell /Applications/Firefox.app/Contents/MacOS/firefox-bin -P & and choose secondary profile
All links transfered from other applications will be opened in primary profile
Ref. https://bugzilla.mozilla.org/show_bug.cgi?id=1653218

This did work for me for several FF/Beta/Aurora version 10+
http://xulforge.com/blog/2011/07/multiple-firefox-instances-mac/
+ https://superuser.com/questions/37811/how-can-i-change-an-application-icon-in-mac-os-x for the icons ;)

Related

Netbeans Apache 12.2 on macOS Big Sur only runs properly as super user

When running as a normal user, if you click on Netbeans->Preferences the window will open, shake, flash, freeze, and not let you do anything. The same thing happens with the Tools->Plugins. Running as super user it works perfectly. I have cleaned up all NetBeans related files. You can see it in action here.
It's useless as it is.
Ive found a partial workaround for this.
You need to setup the OS not to open new documents as new tab.
Go to the Apple Menu, select System Preferences > General. In the Prefer tabs when opening documents option, select "never".
Then restart Netbeans and try to open Netbeans preferences.
If you don't want a system-wide change, you can set the following setting. It should affect only applications running on JDK, run this in terminal:
defaults write net.java.openjdk.cmd "AppleWindowTabbingMode" never
It turns out that is a problem related to the AppleWindowTabbingMode
settings. I was using "always", since I want that apps like Finder and
other use new tabs rather than new windows.
This settings worked fine with NetBeans since Catalina. So I reset the
behavior to "never" only for NetBeans, with the follow command
defaults write net.java.openjdk.cmd "AppleWindowTabbingMode" never
With this setting NetBeans works finally fine!
Sources: apparently, it's a bug, please see here and corresponding JDK bug.
Also, it's not a problem with NetBeans only. It affects AndroidStudio also see here for example:
If you choose to run it as root, here's what I use:
#!/bin/bash
APP=/Applications/NetBeans/Apache\ NetBeans\ 12.2.app/Contents/MacOS/netbeans
COMPLAINT="Netbeans must run as %U because of bugs in the UI implementation :{"
PROMPT=$(echo -e "${COMPLAINT}\nPlease enter your login password for privilege escalation:")
sudo -p "${PROMPT}" -b -s "${APP}"
This lets me limp by with a recent JDK (15.0.2) which placates the corresponding NetBeans (12.2, as you can see from the code). The -b option tells sudo to run the app in the background, which in this case means simply that the Terminal in which you ran this script will not be polluted with JDK whinging about "illegal reflective access".

Can you have 2 solutions open simultaneously in Visual Studio Mac?

I'd like to have 2 windows open to copy files from one solution to another - can I open 2 windows at the same time with different solutions? I can't seem to find the option to do so.
Yes it's possible.
From the terminal, using:
open -n /Applications/Visual\ Studio.app
For example, in Xamarin you're also able to build and run different solutions on different platforms (Android/iOS) using simulators.
From the terminal, you can open a new instance of an app by using
open -n /Applications/Visual\ Studio.app

XCode 4.2: Organizer documentation is locked in a OSX Lion way

I'm using the XCode 4.2 beta (build 4D199) on Lion, and can't access the Developer Documentation in XCode 4.2 anymore. When I attempt to log-in, I get a pop-up telling me the (remote) file is "locked", in the fashion that Lion does these things.
Does anybody have a suggestion what I can do to access the documentation from within the Organizer?
I used to be able to access it without any issues, not sure what changed.
The situation was fixed for me by Apple / XCode itself, as it automatically downloaded the (newly available?) "iOS 5.0 Library" documentation files. Documentation now runs from a complete local copy.
To be sure you get this too you need to have the automatic download of documentation files turned on.
Preferences > Downloads > Documentation > Check for and install updates automatically
(You can also download the files manually by clicking on "Check and install now")
Same here.
To work around this issue, right click on the sign in page and choose "Open Page in Browser". This will open the same resource in Safari.
1.- Download library from: http://developer.apple.com/rss/com.apple.adc.documentation.AppleiPhone5_0.atom
2.- Open with The Unarchiver
3.- Copy file in "Developer/Documentation/DocSets
4.- Open Xcode
Had the same problem. To solve it (well seems like that), i went in
Xcode -> Preferences -> Downloads -> Documentation
Download the parts you need, for me it worked.
As other commenters have stated you should be able to fix these problems by downloading the documentation again. However, given that a complete set of iOS & MacOS documentation clocks in at around 2.0GB here is an alternative method that avoids re-downloading.
Jump to the documentation folder:
cd /Library/Developer/Shared/Documentation/DocSets
Recurse through all the documentation sets and set the current user as the owner:
for f in *.docset; do sudo chown -R $USER $f; done
Unlock the documentation sets:
for f in *.docset; do SetFile -a l $f; done
N.B. Your documentation path may be different (check ~/Library/...), you should make sure that $USER is correctly set to your username, you will need the root password

Testing Firefox Browsers

With Firefox updating more quickly, how do I test my sites on version 3 through the current version? Can I have multiple versions installed? How do I set that up?
You can either run the installer for each (putting them in separate directories) or extract the content of the zip file for your platform.
Running firefox -ProfileManager will allow you to create new profiles (one per firefox version).
You can then run firefox -P <profile> (or create a shortcut in windows (don't forget to edit the properties to add the command line option) or shell script for it).
NOTE: run firefox -? for help.
Yes, you can have multiple versions but you should create a new .profile for each one so data doesn't overlap.

Does the -app command line option work properly in Firefox 4?

I have written some software that makes use of the -app command line option in Firefox to launch XUL applications in Firefox's embedded copy of XULRunner. This all worked fine in Firefox 3.x, however when I try with Firefox 4, Firefox either crashes or does nothing (depending on if it is on Mac or Windows).
I have tried a number of other command line options and many of them seem to be variously broken. (such as -v to print the version information, which crashes on OSX)
Does anyone know if there are already registered bugs about this? Was the removal of -app intentional or was it an oversight? Is there any way to work around this problem?
The -app is maintained in firefox 4 and should work.
I do not know if there is a bug for windows and mac os, but I'm using it on linux for several apps, and it works well (my firefox version is Mozilla Firefox 4.0.1)
Just wanted to bump this - as on Firefox 7, -app does not seem to be there:
$ uname -s -r
Linux 2.6.38-11-generic
$ firefox --version
Mozilla Firefox 7.0.1
$ firefox --help
Usage: firefox [ options ... ] [URL]
where options include:
X11 options
--display=DISPLAY X display to use
--sync Make X calls synchronous
--g-fatal-warnings Make all warnings fatal
Firefox options
-h or -help Print this message.
-v or -version Print Firefox version.
-P <profile> Start with <profile>.
-migration Start with migration wizard.
-ProfileManager Start with ProfileManager.
-no-remote Open new instance, not a new window in running instance.
-UILocale <locale> Start with <locale> resources as UI Locale.
-safe-mode Disables extensions and themes for this session.
-jsconsole Open the Error console.
-browser Open a browser window.
-new-window <url> Open <url> in a new window.
-new-tab <url> Open <url> in a new tab.
-preferences Open Preferences dialog.
-search <term> Search <term> with your default search engine.
-private Enable private browsing mode.
-private-toggle Toggle private browsing mode.
-setDefaultBrowser Set this app as the default browser.
-g or --debug Start within debugger
-d or --debugger Specify debugger to start with (eg, gdb or valgrind)
-a or --debugger-args Specify arguments for debugger
I too would love to know when and why it was removed, but I simply cannot find any info online (see also Single-file app with xulrunner - possible?) ...
PS: Just filed a bug here: Bug #880596 in firefox (Ubuntu): “Option '-app' missing from Firefox above version 3” - I thought it would be automatically copied to mozilla's bugzilla (seeing bugs like Bug #207454), but unfortunately, it wasn't so... - bugzilla bug needs to be copied and added manually, it's there now...
I also experienced problems using the -app switch. I'm using Firefox 10, but I have an idea this problem goes right back to FF 4.
The firefox binary, when run with the -help option, does not show list the -app option, which caused me much confusion, but I believe its still there.
The problem for me, instead, was to do with this change in Firefox 4, requiring a chrome manifest file in the application root. Since FF 4, only a single (root) chrome manifest is read, so you must create one with the following line, (or lines, if you want to have multiple manifests).
manifest chrome/chrome.manifest
Then launch the application the usual way
firefox -app path/to/application.ini -jsconsole
(For debugging use the -jsconsole option).
Another note, (you didn't mention having tried this, but I did and it was wrong) -- don't use the -no-remote option. I tried this with the intent of starting a new process for my XUL application separate from already running firefox instances. However, the -app option will create a new process for your application even if firefox instances are already running, so there is no need.
See also this question for more info about the chrome manifest issue.

Resources