I'm reasonably new to OS X, but I'm familiar with Vim from using it in various *nix systems. I've seen many people recommend running MacVim over Vim in the terminal. Can anyone tell me what differences there are between MacVim and regular Vim?
相关问题
- Xcode debugger displays incorrect values for varia
- Is there a way to report errors in Apple documenta
- Advice for supporting both Mac and Windows Desktop
- Emacs shell: save commit message
- Avoid cmake to add the flags -search_paths_first a
相关文章
- 如何让 vim 支持 .cshtml 文件的代码高亮
- 现在使用swift开发ios应用好还是swift?
- Visual Studio Code, MAC OS X, OmniSharp server is
- Auto-save in VIM as you type
- xcode 4 garbage collection removed?
- IntelliJ IDEA can't open projects or add SDK o
- Automator: How do I use the Choose from List actio
- ImportError: No module named twisted.persisted.sty
MacVim is just Vim. Anything you are used to do in Vim will work exactly the same way in MacVim.
MacVim is more integrated in the whole OS than Vim in the Terminal or even GVim in Linux, it follows a lot of Mac OS X's conventions.
If you work mainly with GUI apps (YummyFTP + GitX + Charles, for example) you may prefer MacVim.
If you work mainly with CLI apps (ssh + svn + tcpdump, for example) you may prefer vim in the terminal.
Entering and leaving one realm (CLI) for the other (GUI) and vice-versa can be "expensive".
I use both MacVim and Vim depending on the task and the context: if I'm in CLI-land I'll just type
vim filename
and if I'm in GUI-land I'll just invoke Quicksilver and launch MacVim.When I switched from TextMate I kind of liked the fact that MacVim supported almost all of the regular shortcuts Mac users are accustomed to. I added some of my own, mimiking TextMate but, since I was working in multiple environments I forced my self to learn the vim way. Now I use both MacVim and Vim almost exactly the same way. Using one or the other is just a question of context for me.
Also, like El Isra said, the default vim (CLI) in OS X is slightly outdated. You may install an up-to-date version via MacPorts or you can install MacVim and add an alias to your
.profile
:to have the same vim in MacVim and Terminal.app.
Another difference is that many great colorschemes out there work out of the box in MacVim but look terrible in the Terminal.app which only supports 8 colors (+ highlights) but you can use iTerm — which can be set up to support 256 colors — instead of Terminal.
So… basically my advice is to just use both.
EDIT: I didn't try it but the latest version of Terminal.app (in 10.7) is supposed to support 256 colors. I'm still on 10.6.x at work so I'll still use iTerm2 for a while.
EDIT: An even better way to use MacVim's CLI executable in your shell is to move the
mvim
script bundled with MacVim somewhere in your$PATH
and use this command:EDIT: Yes, Terminal.app now supports 256 colors. So if you don't need iTerm2's advanced features you can safely use the default terminal emulator.
unfortunately, with "mvim -v", ALT plus arrow windows still does not work. I have not found any way to enable it :-(
The one reason I have which made switching to MacVim worth it: Yank uses the system clipboard.
I can finally copy paste between MacVim on my terminal and the rest of my applications.