macvim

“dyld: Library not loaded”, “libruby.1.9.1.dylib” when calling “mvim .” in the command line

只谈情不闲聊 提交于 2019-12-01 00:41:24
问题 I'm trying to open my rails project into mvim (macvim) using "mvim ." but I get the following error. ➜ cs193p git:(master) mvim . dyld: Library not loaded: /Users/myusername/.rvm/rubies/ruby-1.9.3-p125/lib/libruby.1.9.1.dylib Referenced from: /usr/local/Cellar/macvim/7.3-64/MacVim.app/Contents/MacOS/Vim Reason: image not found [1] 85219 trace trap mvim . ➜ cs193p git:(master) mvim --version dyld: Library not loaded: /Users/myusername/.rvm/rubies/ruby-1.9.3-p125/lib/libruby.1.9.1.dylib

Alter $PATH in vim/macvim so as to find the right ruby binary

喜你入骨 提交于 2019-11-30 15:52:08
In trying to harmonize environments between a ZSH session and the vim/macvim access of the shell, a which ruby from the shell shows $HOME/.rvm/rubies/ruby-1.9.3/bin/ruby , which is good, while from inside vim/macvim a !which ruby shows /opt/local/bin/ruby , which is bad. I thought copying the invocation of RVM from .zshrc to .zshenv would work but doing so interferes with other utilities. After several days trying to sort this out, I feel stumped. Any suggestions of where documentation to resolve this can be found would be most appreciated. I don't know if it applies to zsh but depending on

Changing background color in vim at a certain column

て烟熏妆下的殇ゞ 提交于 2019-11-30 11:56:49
问题 I'd like to be able to highlight the wrap margin/text width in vim by changing the background color (or maybe just a line?). A lot of IDEs have this. I mocked up what I'm talking about: Anyone know if this can be done in macvim or gvim? 回答1: Try this: :match ErrorMsg '\%>80v.\+' It will highlight text beyond 80 characters, you can replace '80' with whatever wrap-width you have. However, it will only highlight the characters that exceed the width, and then only on lines that are actually

Disable use of MacVim keyboard shortcuts

末鹿安然 提交于 2019-11-30 07:11:31
Is there any way to disable keyboard shortcuts in MacVim? I mean the shortcuts like Cmd + s for example, I want to convince myself to use things like :w , but I can't do so if I can save the file using Cmd + s , you get me? But I of course, still want to use the GUI, so is there any way to disable these, without stoping using the MacVim GUI? Thanks for your help. BTW I made a Google search and wasn't able to find an answer. EDIT: Following @ChrisJohnsen's suggestion, I have already tried the following with no success: if has('gui_running') macmenu File.Save key=<nop> macmenu File.Save\ As\.\.\

值得收藏!神级代码编辑器 Sublime Text 全程指南

青春壹個敷衍的年華 提交于 2019-11-30 01:49:55
作者: Lucida 微博: @peng_gong 豆瓣: @figure9 原文链接: http://lucida.me/blog/sublime-text-complete-guide/ 摘要(Abstract) 本文系统全面的介绍了Sublime Text,旨在成为最优秀的Sublime Text中文教程。 前言(Prologue) Sublime Text是一款跨平台代码编辑器(Code Editor),从最初的Sublime Text 1.0,到现在的Sublime Text 3.0,Sublime Text从一个不知名的编辑器演变到现在几乎是各平台首选的GUI编辑器。而这样优秀的编辑器却没有一个靠谱的中文教程,所以我试图通过本文弥补这个缺陷。 编辑器的选择(Editor Choices) 从初学编程到现在,我用过的编辑器有EditPlus、UltraEdit、Notepad++、Vim、TextMate和Sublime Text,如果让我从中推荐,我会毫不犹豫的推荐Vim和Sublime Text,原因有下面几点: 跨平台: Vim和Sublime Text均为跨平台编辑器(在Linux、OS X和Windows下均可使用)。作为一个程序员,切换系统是常有的事情,为了减少重复学习,使用一个跨平台的编辑器是很有必要的。 可扩展: Vim和Sublime

Changing background color in vim at a certain column

做~自己de王妃 提交于 2019-11-30 01:45:06
I'd like to be able to highlight the wrap margin/text width in vim by changing the background color (or maybe just a line?). A lot of IDEs have this. I mocked up what I'm talking about: Anyone know if this can be done in macvim or gvim? Try this: :match ErrorMsg '\%>80v.\+' It will highlight text beyond 80 characters, you can replace '80' with whatever wrap-width you have. However, it will only highlight the characters that exceed the width, and then only on lines that are actually longer than the width. Check http://vim.wikia.com/wiki/Highlight_long_lines for more info, but they all pretty

Alter $PATH in vim/macvim so as to find the right ruby binary

雨燕双飞 提交于 2019-11-29 22:50:49
问题 In trying to harmonize environments between a ZSH session and the vim/macvim access of the shell, a which ruby from the shell shows $HOME/.rvm/rubies/ruby-1.9.3/bin/ruby , which is good, while from inside vim/macvim a !which ruby shows /opt/local/bin/ruby , which is bad. I thought copying the invocation of RVM from .zshrc to .zshenv would work but doing so interferes with other utilities. After several days trying to sort this out, I feel stumped. Any suggestions of where documentation to

Autocompletion in Vim

不想你离开。 提交于 2019-11-29 18:36:25
After a long "training", I have finally switched to Vim; but I have some trouble with the autocompletion. How can I have a code suggestion while I'm typing? I usually develop PHP, Ruby, HTML, C and CSS. You can use a plugin like AutoComplPop to get automatic code completion as you type. 2015 Edit: I personally use YouCompleteMe now. Orbit Use Ctrl - N to get a list of word suggestions while in insert mode. Type :help i_CTRL-N to see Vim's documentation on this functionality. Here is an example of importing the Python dictionary into Vim. You can start from built-in omnifunc setting. Just put:

UltiSnips and YouCompleteMe

人走茶凉 提交于 2019-11-29 18:36:13
I have bundles ultisnips and youcompleteme installed on my macvim. The problem is that ultisnips doesn't work because tab is bound by ycm. I tried putting let g:UltiSnipsExpandTrigger = "<s-tab>" so that I can trigger the snippet completion with shift-tab, but it doesn't work for some unknown reason. I could use caps as the trigger, but so far I've found no way to do that. Do any of you use those two add-ons together? What can I do to make shift-tab work? Can you recommend another key to trigger snippets? Siegfried Gevatter Another option is using the SuperTab plugin: " if you use Vundle, load

Disable use of MacVim keyboard shortcuts

核能气质少年 提交于 2019-11-29 09:07:59
问题 Is there any way to disable keyboard shortcuts in MacVim? I mean the shortcuts like Cmd + s for example, I want to convince myself to use things like :w , but I can't do so if I can save the file using Cmd + s , you get me? But I of course, still want to use the GUI, so is there any way to disable these, without stoping using the MacVim GUI? Thanks for your help. BTW I made a Google search and wasn't able to find an answer. EDIT: Following @ChrisJohnsen's suggestion, I have already tried the