Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a way to make Firefox open a new window on a certain URL or raise the tab/window where that URL is already loaded?

I would like to call Firefox with

firefox --open-or-focus http://example.com

and have Firefox either

Firefox already have a similar functionality embedded in the location bar (try typing an address which you already have in an open tab), is it exposed to the command line as well?

share|improve this question
    
gioele: Upvote but no answer acceptance? – JAnderton May 30 '13 at 19:10

Mozilla's documentation for Firefox's command line arguments doesn't write about any such feature. I tried to check the documentation available on firefox's binary as well and it doesn't do this.

You have switches to open new tabs and new windows but none to get a list of tabs open which you could potentially read off a script.

Simple answer, can't be done unless you start reading the Firefox profiles to figure it out. Doesn't seem worth the effort :)

Also, another thing I noticed when running Firefox off command line is that it blocks your terminal to keep the process running (I'm running this off a Mac but it should be the same for Linux). If you do want to CLI Firefox in a linux environment (considering the tags this post has), you might want to screen it.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .