Question

I'm using MacVim and would like to be able to open mvim, set it to the current directory and open a new buffer in one command. Currently I do "mvim ." (where mvim is aliased to "mvim --remote-silent"). However this also automatically opens a netrw window (I assume because I tried to open a directory in mvim).

Is there any way of disabling this and only opening a blank buffer (while setting the working directory to the current one)?

EDIT: Here's the script that does what @Amadan suggested:

if [ $# -eq 0 ]
  then
    mvim
  else
    mvim --remote-silent "$@"
fi
Was it helpful?

Solution

mvim by itself does what you want. (The original one, not the --remote-silented one)

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top