Join the AMA (Ask Me Anything) with the Firefox leadership team to celebrate Firefox 20th anniversary and discuss Firefox’s future on Mozilla Connect. Mark your calendar on Thursday, November 14, 18:00 - 20:00 UTC!

Ce site disposera de fonctionnalités limitées pendant que nous effectuons des opérations de maintenance en vue de vous proposer un meilleur service. Si un article ne règle pas votre problème et que vous souhaitez poser une question, notre communauté d’assistance est prête à vous répondre via @FirefoxSupport sur Twitter, et /r/firefox sur Reddit.

Rechercher dans l’assistance

Évitez les escroqueries à l’assistance. Nous ne vous demanderons jamais d’appeler ou d’envoyer un SMS à un numéro de téléphone ou de partager des informations personnelles. Veuillez signaler toute activité suspecte en utilisant l’option « Signaler un abus ».

En savoir plus

--new-tab on linux command line opens new window even when an instance is already running

more options

I sometimes invoke firefox on Linux by running the command

`firefox --new-tab` (with no argument to the new tab flag, I have this hooked to a keyboard shortcut).

This has always worked fine (opens a new instance of firefox if none is running; opens a new tab in the open window if there is one). Today I upgraded to Firefox 79.0, and unfortunately it seems that now running the above command opens a new window even if I already have one open. I guess this is a regression?

I sometimes invoke firefox on Linux by running the command `firefox --new-tab` (with no argument to the new tab flag, I have this hooked to a keyboard shortcut). This has always worked fine (opens a new instance of firefox if none is running; opens a new tab in the open window if there is one). Today I upgraded to Firefox 79.0, and unfortunately it seems that now running the above command opens a new window even if I already have one open. I guess this is a regression?

Solution choisie

Using -new-tab without a URL following isn't documented currently. Not sure whether it used to be documented:

https://developer.mozilla.org/docs/Mozilla/Command_Line_Options#Browser

You could add a URL to your shortcut (e.g., "about:blank").

Or file a bug if you don't need it for a while: https://bugzilla.mozilla.org/

Lire cette réponse dans son contexte 👍 0

Toutes les réponses (5)

more options

~~It works properly for me~~ ~~firefox 79.0~~ ~~archlinux~~

~~proof: https://imgur.com/iJRU5gU~~

Modifié le par Chinmay

more options

Hi DenverCoder9, does it seem to be a new instance of the identical Firefox, or are there differences? I'm asking because this can happen when your first instance of Firefox is not running what is recorded in various config files as your default Firefox profile.

To see which profile each window is using, you can check the Troubleshooting Information page. Either:

  • "3-bar" menu button > "?" Help > Troubleshooting Information
  • (menu bar) Help > Troubleshooting Information
  • type or paste about:support in the address bar and press Enter/Return

In the first table on the page, find the Profile Folder row and check the last part of the path. Same profile? Different?

You might also check the Application Binary to see whether you have two Firefox installs.

Depending on what you find, we'll have different recommendations.

more options

Oh no actually without specifying the website, it opens a new window for me too. The profile folders and the application binaries are the same in both the windows


ie `firefox https://duckduckgo.com --new-tab` opens a new tab in the already running window. `firefox --new-tab` opens a new window

Modifié le par Chinmay

more options

Thanks for the update, Chinmay.

@jscher2000, I just checked: the windows have the same profile directory and also the same application binary. FWIW also, if I just keep running the command, it is always opening a new window, even with the one it just opened still there.

more options

Solution choisie

Using -new-tab without a URL following isn't documented currently. Not sure whether it used to be documented:

https://developer.mozilla.org/docs/Mozilla/Command_Line_Options#Browser

You could add a URL to your shortcut (e.g., "about:blank").

Or file a bug if you don't need it for a while: https://bugzilla.mozilla.org/