Skip to content

Instantly share code, notes, and snippets.

@michaellee
Last active August 29, 2015 14:03
Show Gist options
  • Save michaellee/d155b9b9f26dedd0d9cc to your computer and use it in GitHub Desktop.
Save michaellee/d155b9b9f26dedd0d9cc to your computer and use it in GitHub Desktop.
Launch MacVim from the Mac OS X Terminal

Launch MacVim from the Mac OS X Terminal

MacVim is a great complement to Vim for the Mac. One of the reasons why I started using MacVim was its built in support for the yank command to copy to the system's clipboard.

To get a copy of MacVim, you can grab the latest snapshot here.

When you download a snapshot of MacVim, you'll find a compressed file that includes MacVim.app, mvim (a command-line tool) and a README file.

One of the great things about using vim is that you can simply type vim filename.md to open a file in vim from within the terminal. The mvim cli enables us to do the samething.

Installation

After installing MacVim by dragging MacVim.app to the Applications folder, open up terminal and navigate to the uncompressed folder that has mvim.

Then we're going to move the mvim file to /usr/local/bin by typing in this command from the terminal:

mv mvim /usr/local/bin/

Now whenever you're in Terminal and want to open a file with mvim simply type:

mvim filename.md

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment