macvim

MacVim - executing a shell script not working..?

Hello all, I have written a custom shell script function, and put in in my .profile. When I run the command that executes the function from my terminal, it works just fine, however when I run the command from MacVim, it does nothing. The function in my .profile is not being run when I run the command from Macvim. How to I get this to...

vim how to create a debug message fast

I am using ruby on rails but that does not matter much for this question. Let's say that i have a statement like this error = 'this is an error message' I have noticed that I end up doing this a lot error = 'this is an error message' puts "error = #{error.inspect}" I am sure a macro can be written which would take the work on the l...

Execute a script directly within vim/mvim/gvim

TextMate has a nice feature that allows you to execute a script from within the current context and shows you the output in a separate window. This lets you write and test code on the go. I'm almost certain there is a similar feature with MacVim/gVIM, but I'm not sure what it is. Currently I save my buffers to disk, then go to the comman...

Is there a quick way with macvim/NERDtree plugin to find a file?

What's the fastest way to find and open a file with MacVim? NERDtree is a great plugin, but I still have to navigate (sometimes very deep) directory trees in order to get to the file I want to get to. Is there any functionality that allows me to search a substring of a file name and show me a result set I can click on from that? ...

vim: plugin that allows me to jump from opening div to closing div in HTML?

I'm having a difficult time to find an opening div in deeply nested HTML that has been poorly written. Is there a plugin out there that will give me support to jump to the equivalent open/closing div using vim/gvim/macvim and other variants? ...

Easily create a Ruby on Rails partial from an existing block of markup using vim

Is there currently a plugin that you ruby on rails developers that are also using macvim/gvim/vim that allows you to take a quick block of code and create a partial from it? I know that TextMate does this, figured someone has ported it by now to vim also. ...

NERDTree vim plugin, trying to add file without success

To my understanding, you can add files directly from MacVim with the NERDTree plugin. I navigate to NERDtree and hit 'm' to bring up the NERDTree filesystem menu as described in this post: http://stackoverflow.com/questions/1459750/vim-and-nerd-tree-extension-adding-a-file The problem is, I get this output after invoking 'm': NERDTree ...

$PATH variable not properly set in gvim/MacVim when it is opened from the finder

I am using MacVim (basically gvim for the mac). If I open macvim from the command line then my $PATH variable will be properly set. If I open macvim via point and click with the finder, the $PATH variable will NOT be properly set. Can anyone give me some insight? Note: I know at least part of my path is set in ~/.bashrc, but ...

vim/macvim: locate where a method/symbol is defined

I'm using macvim/vim for most of my Ruby + Ruby on Rails development. Is there currently a way to jump to where a method was defined within a project, even if it's not in the same file as where it's being invoked? Either a language agnostic way or a Ruby/Rails specific way works. ...

Disable Vim plugin for certain filetypes

Hi all, I'd like to disable a plugin for certain filetypes in Vim. I'm a Vim newbie, so take it slow with me :) I have the autocomplpop plugin, and I really like it. However, if I'm editing a LaTeX file, it shows completions for every single English language word I've already used. It's distracting! I'd like to disable it for .tex file...

Macvim and rails.vim on rails 3 rc - Uninitialized constant Bundler (NameError)

Configured vim and gvim on Windows, as well as vim and macvim on OSX. Intend to learn rails 3, so installed rails 3 rc on both OS'ses. So far, so good. When using macvim, each and every script execution offered by rails.vim gives me errors "Uninitialized constant Bundler (NameError)". Tried :Rserver, :Rgenerate, .... However, staying on...

Vim: Highlight keyword pairs in Ruby (def/end, do/end, etc)

In one of the Eclipse-based editors that I tried out recently (I think it was RubyMine), when a Ruby keyword that either opened or closed a method or block was selected, the corresponding open/close keyword was highlighted. Similar to the way that Vim is able to highlight a corresponding open/close parenthesis. For instance, if I select...

[MAC|G] VIM: highlight all occurrence of a selected word?

How can I highlight all occurrence of a selected word in gvim? (like notepad++..) ...

MacVim Open File In Existing Window

Is there a way to set up MacVim to open a new file in the current window in a running MacVim instance? I currently have the MacVim preference "Open new files in a new tab in the current window" set, but ideally I'd just like to open new files the way ":e new_file" works, without the tabs. My main motivation is that I currently use NERDT...

Recursive Tab Complete Filenames on :edit in VIM

I had found a .vimrc configuration that allowed me to simply type :e <<characters_in_filename>> and then tab and the path would expand out to :e full_path or show me a list of options if there are similarly named files in my current path. Anyone know how to make this happen? note: I'm away of FuzzyFileFinder, Peepopen, and Command...

vim: is there a plugin to show all of your TODO tags in source?

Like most of you, I work in several source files of code every day. A lot of the time, my insane work flow has me doing stuff like: # TODO # clean up this code # do something else with this code Is there currently a vim plugin available that will search for TODO or a similar mnemonic and print a list of my current tasks that are on-go...

NERDTree does not open in the directory from which macvim was opened

I upgraded my macvim to 7.3 recently and I can no longer open nerdtree or netw in the directory in which macvim was opened, it always opens in my home directory. For example, If I open macvim in /users/me/test/project dir, I want the NERDTree root to be /Users/me/test/project and not /Users/me. Any ideas? ...

Prevent vim from changing directories when opening files

I just updated my MacVim to 7.3 and with it, it now changes directories to whatever file I'm currently editing. I use PeepOpen, so it's incredibly annoying to cd back to my project directory every time I want to edit a new file. ...

A shortcut to add a line

In my current project I end up typing this line a lot Then show me the page How should I create a shortcut mapping so that if I am on a line and hit that shortcut then a new line just below the current line is created and the above mentioned line is added. It would be nice if the newly added line has the same indentation as the abov...

Compiled vim from source on Mac OSX and getting 'shell returned 127' error?

Hello. On my Mac OSX 10.6 machine, I started to use MacVIM for vim. Then I noticed my terminal version was different to the MacVIM version (MacVIM was 7.3 and my terminal version 7.2)... I thought they used the same vim? I need 7.3 for some of the features. So I set about wanting to update the terminal version. I basically cloned it us...