mvim (MacVim 7.4) opening new windows rather than tabs (Mac OS X 10.8.5)

use the --remote-tab command line switch, as in:

mvim --remote-tab foobar.txt

The answer was obtained by reading help:mvim it is located in section 14 of the help file titled macvim-hints.

Extracted here is the relevant section of the MacVim 7.4 help file:

Scenario:

~ You want to open a file in a tab in an already opened window, but typing "mvim filename" in Terminal opens it up in a separate window.

Solution:

~ Use the |--remote-tab| switch. If you have several windows open you might have to specify which window you want the file to open in by using the |--servername| switch. The title of a window usually ends in something like "VIM" or "VIM3" --- this is the server name of that window. So to open a file named "foobar.txt" in a window whose title ends in "VIM3" you would type (the order of the arguments matters):

mvim --servername VIM3 --remote-tab foobar.txt

For more information, consult the |client-server| manual page.