Opening file using command line doesn't map to right window when using multiple projects

If a file is opened using the command line, WebStorm/IDEA should check all of its windows to see if that file is open in any of them. If it is already open in an existing window then IDEA should bring window and the correct tab to the front.

Currently the IDEA only seems to check the last active window. So even if a file is already open in an existing tab in a second window, a new tab will be opened in the first.

Optimally, if the file isn't open in any of the windows, IDEA should scan the projects themselves to see if the file exists in any of the projects. If the file is in one of the existing projects, then the new tab should be opened in that project's window. In the rare case where a file exists in multiple projects, I would say it should just open in one of them.

I'll add that when IDEA has multiple projects/windows it's still a single process so it should be very doable to walk through all the window's tabs.

PS, If someone does work on tweaking this command line behavior, while you are in that bit of code it would be great if you could also look at adding a line number argument like I describe at


WebStorm WS-98.271
Windows XP

Comment actions Permalink

Hi David,

You better post your request to issue tracker directly (since your post is not really a question but rather bug report/feature request -- you clearly know where IDE behaves wrong and how it should actually behave): Each task would go there anyway in order to be implemented -- if not entered by you then by somebody from the dev team (which may take few days or even longer).

In regards to "adding a line number argument" -- please vote/comment these feature requests: &

Comment actions Permalink

Thanks for the tip! I created a new issue -, and also commented on the others you mentioned.


Please sign in to leave a comment.