Vim's configuration file.

learn more… | top users | synonyms

0
votes
1answer
24 views

vim how to unmap [[

The :map [ shows following n [[ *@m':call search('^\s*fu\%[nction]\>', "bW")<CR> n [c <Plug>GitGutterPrevHunk n [ * :w<CR> :unmap [c ...
0
votes
0answers
33 views

Mac command button working in the MacVim GUI but not when I run MacVim in the terminal?

I am running MacVim in my terminal (iTerm2) using alias vim='mvim -v' (mentioned in this thread: http://stackoverflow.com/questions/2056137/how-to-run-mvim-macvim-from-terminal). In my ~/.vimrc file ...
0
votes
2answers
34 views

Keybinding to make End go one character past the last character on the line

By default the End key takes me to the last character on the line in Vim. However, I have set virtualedit=onemore in my vimrc, and I actually want End to take me one character past the last character. ...
0
votes
0answers
13 views

Vim solarized seems to mixup color

My vim: This is how my looks, look at the change in color from line 38 onwards. Any solution for this?
0
votes
3answers
54 views

How can I remove the dependency of having a `vimfiles` folder in windows?

On linux I can put my colors/syntax/bundle folder right into .vim which doesnt seem to work on windows, it forces me to put them into a subdirectory called vimfiles. Ill try to visualize what I want ...
1
vote
0answers
29 views

vim recent changes breaks vmap?

The same procedure works on my VIM 7.4 patch 1-1572 but not on my VIM 7.4 patch 1-1718, is there anything changed in between that affects this? Procedure: $ vim -u /dev/null some-file Then in vim ...
1
vote
0answers
30 views

Make part of php comment line bold in vim

I've a PHP script, and I would like to know if natively, I can make a part of a comment line BOLD. For example a comment : // it is released when you execute RELEASE_LOCK(), execute a new ...
0
votes
2answers
50 views

Get rid of vim sidebar and top bar

I just installed Amix' Vimrc and can't figure out how to get rid of the top bar with the file name and the gray bar on the right side of the window any help is much appreciated.
0
votes
1answer
18 views

Multi display: how to restore last gVim display?

I have 2 displays. I start gVim. It window always opens on display 1. I move it to dislpay 2 then close it. After this I start gVim again. It opens on display 1 again but I want it to open on display ...
1
vote
0answers
115 views

How to setup in `~/.vimrc` a mapping for `colorscheme` to toggle `solarized` between `dark` and `light`?

How to setup in ~/.vimrc a mapping for colorscheme to toggle solarized between dark and light? Both background and colorscheme in ~/.vimrc are badly misbehaving! I have setup solarized to work on ...
0
votes
1answer
214 views

Vim error - E138: Can't write viminfo file

I have already checked several similar links but nothing worked. Before i explain the issue, i was earlier getting following message while saving any file: vim e509 Cannot create backup file (add ! ...
0
votes
1answer
60 views

Replace 8 spaces tabs with 4 spaces tabs

I added set tabstop=4 set softtabstop=4 set shiftwidth=4 to my .vimrc file. But tabs in my existing files are still taking 8 spaces. How can I update them?
1
vote
1answer
64 views

Execute Command on VIM Exit, And View the Output

I use vim for editing my PHP scripts, and I would like vim to automatically execute php -l on any *.php file that I exit to do a syntax check. I've set this autocmd in my ~/.vimrc file: autocmd ...
0
votes
2answers
26 views

How to show ident level on vim instead of tab markings?

my .vimrc shows vertical lines so i can follow identation blocks easily, like pretty much every single text editor/IDE. if(x == 1){ | if( y == 1){ | | y(); | } } is there any way i can make ...
-1
votes
1answer
26 views

Print tag folder in vim

I got this line in my .vimrc so that it look i parent directories untill it find a tag file. set tags=./tags; Is there a way to print the directory where vim found the tag file inside vim?
0
votes
0answers
9 views

MacVim cmd+a (select all) no longer works

I haven't tweaked my .vimrc for MacVim in a while. But I notice recently cmd+a no longer works. Instead it clears the buffer and types a g instead: When I go: :verbose nmap <D-a> It says: no ...
0
votes
1answer
19 views

vim user defined command: reopen current file for editing

I have a user defined command in vim that does a chmod on the current file. Once that's done, reopen the current file for editing (with the newly updated properties) by issuing: :e[dit]! I'd like ...
0
votes
0answers
34 views

Vim Background color issue

I want my vim background to be dark but as you can see it's not, its half black half grey, I'm using Ubuntu 15.10 with latest Vim version. How to fix this?
1
vote
0answers
69 views

.vimrc sourcing another leads to plugin errors

Since vim or vim-pymode does not seem to work with both python 2 and 3 at the same time I thought I make an alias for my newly compiled vim version specially for developing python 3. So I added this ...
1
vote
2answers
80 views

Vim; Shortcut to add comment at beginning of line

When I code, I tend to execute the following manually a lot after having selected multiple lines of code. :'<,'>s/^/#/ I want to add this to my .vimrc but I am having troubles making it work. ...
0
votes
1answer
42 views

Does resourcing my .vimrc unset the mark created when writing buffer?

The first line returns the cursor to the line i was on, the second sources the resource file. both work on there own but will not work together. The marks set by Return cursor seem to still be set, ...
1
vote
1answer
34 views

Vim Return to last point in file

can anybody provide an explanation as to what this is doing or point me to vimdocs? line("'\"") function! ResCur()$ if line("'\"") <= line("$") normal! g`" return 1 endif$ endfunction ...
0
votes
0answers
12 views

Cross-platform .vimrc/_vimrc [duplicate]

I use vim on windows (GVim portable off a USB stick) and Linux (standard command-line vim) and would like to synchronise my settings (_vimrc or .vimrc respectively). As far as I can see (I haven't ...
1
vote
1answer
331 views

Color scheme(s) in Vim not properly working

On Archlinux, using Vim 7.4 (installed with pacman), I tried to use the lucius color scheme. However, the moment I turned it on, all color went away. This happened in the Xfce Terminal emulator under ...
0
votes
1answer
142 views

Solarized color scheme did not come out as expected after installation

After I install solarized, the background color didn't come out as expected. vim uses terminal black background instead of using solarized's blue background. My terminal is also set to Xterm-256color. ...
0
votes
1answer
134 views

Stop Vim from automatically tw=78 line-break wrapping text files

I recently updated Vim, and noticed that whenever I open a .txt file, the option tw=78 is set. (Which makes Vim automatically break lines when they would have exceeded 78 characters.) I don't like ...
0
votes
1answer
69 views

How do I fold my .vimrc non-temporarily using vim code-folding? (sp13-vim)

I'm using spf13-vim, and I wanted to keep my vimrc folded into sections like this +------126 lines: Environment {---------------------------------------------------------------------------------------...
0
votes
1answer
276 views

How to map ctrl/p clear cache and refresh NERDTree root node?

How do I map <leader>r which clears CtrlP's cache and refreshes NERDTree's root directory? Pseudo code, I have: map <Leader>r :CtrlPClearCache<cr>g:NERDTreeMapRefreshRoot<cr> ...
2
votes
1answer
37 views

Effectively manage sets of Vim settings

Is there any effective way to manage multiple sets of Vim configuration? I need this because I need different sets of configuration for different types of work. It depends a lot whether I'm writing a ...
0
votes
1answer
79 views

How to autocomplete python class in vim

In sublime text 3, if I'm editing a file.py and I type class it will automatically create this for me class ClassName(object): """docstring for ClassName""" def __init__(self, arg): ...
0
votes
1answer
44 views

Vim: Managing multiple wording alternatives

(After reading this, please suggest another wording for the question, because I couldn't come up with a better one) When writing and editing in Vim, whether texts for humans or texts for humans and ...
0
votes
1answer
151 views

The risk of vim -Z (rvim)

Last time I asked about the way to prevent risks caused by these configurations: user_name ALL=(ALL) /usr/bin/vim /etc/httpd/confs/httpd.conf or %group_name ALL=(ALL) /usr/bin/vim /etc/httpd/confs/...
2
votes
4answers
429 views

Vim copy/paste messing up indentaton

Whenever I copy something from another application and then go to paste it into vim, it messes up the indentation. For example, just now I tried to copy the manifest.json file from the hello-world ...
0
votes
1answer
27 views

Wordskip in vim [ssh from mac to linux]

Word skip (ctrl key and arrow keys) work fine with vim on my mac in terminal. But, when I ssh from my mac to my linux box, ctrl and arrow key do not work (wordskip) instead delete a bunch of lines ! ...
1
vote
1answer
274 views

YouCompleteMe set flags for filetype

let g:syntastic_c_compiler = 'clang' let g:syntastic_c_compiler_options = ' -ansi -pedantic' let g:syntastic_cpp_compiler = 'clang++' let g:syntastic_cpp_compiler_options = ' -std=c++11 -stdlib=libc++ ...
2
votes
1answer
173 views

How to include all Vim config files in some folder?

I want to reorganization my vim directory to be like this: - dotfiles |- vim | |- config | | |- global | | | |- basic.vim | | | |... | | |- plugins | | | |- ctrl-p.vim | ...
0
votes
1answer
59 views

vim: Mapping from .vimrc not applied

In my vimrc, i mapped nnoremap <tab> >> and nnoremap <s-tab> <<. The second mapping works fine, the first one however seems to be forgotten. If i map it manually when in vim, ...
0
votes
3answers
265 views

Disable vim plugins for large files

I have a custom Vim configuration that I've been putting together. There's a number of cool plugins and features that aid in PHP development. However, when I open a large file (couple thousand lines) ...
1
vote
1answer
525 views

sourcing the .vimrc gives E174 error

I am using vim on a Mac os X. After editing my .vimrc file and I want to try to reload it without restarting vim. But it gives me the following error. E174: Command already exists: add ! to replace ...
1
vote
2answers
98 views

vim: library of common substitutions without plugins?

I would be wanting to perform thinks like :'<,'>s/^\ \ \ \ // in an abbreviated form, like :'<,'>s_lw (no matter what would actually be that s_lw) using vim base functionality, initially ...
0
votes
1answer
104 views

vim's vimrc messes up vim completely

i am using manjaro linux, and i installed vim using $ sudo pacman -S vim then i modified my vimrc file $ sudo vim /etc/vimrc then i added some cool things: set background="dark" set number set ...
0
votes
1answer
47 views

How to run something insert mode, get user input then return to insert mode?

I have inoremap <C-d> <C-o>:%s/\<<C-r><C-w>\>\C//g<Left><Left>, which works great (emulating sublime text's find-all multi cursor more or less). However it ...
0
votes
1answer
300 views

VIM Crashes/Freezes on specific files Mac OSX Mavericks

I've recently switched over to using VIM and use a friends .vimrc that works well for him https://github.com/dtothefp/dotfilesv2/blob/master/vim/vimrc.symlink I first installed vim through Homebrew ...
1
vote
1answer
37 views

Vim - mapping for moving between buffers silently

in my .vimrc I have the following mapping to move between buffers: nnoremap <silent> <C-b> :bp<CR> nnoremap <silent> <C-n> :bn<CR> This mapping works but it ...
0
votes
1answer
134 views

Can't remap ctrl or alt combinations to commands

In Vim, I am ttempting the following remaps: nnoremap <A-1> :make<CR> inoremap <A-1> <Esc>:make<CR>i Basically, I want to remap alt+1 to :make. However, this remap ...
1
vote
1answer
570 views

Vim - How Recognize Spaces as Tabs (set listchars=tab)

I wonder if it is possible to use a configuration for that command "set listchars=tab:▒░,trail:·" to "see" 4 spaces as tabs and get the effect of the picture below (using real tabs)... I use the ...
3
votes
2answers
164 views

How can I construct a vim keymapping that inserts the current date?

I'm trying to create a vim keymapping that will initiate the creation of a new file, with the name of the file prefixed with the current date, waiting for me to finish typing the filename. Put more ...
0
votes
1answer
44 views

Conflicting hlsearch colours vim

I've switched from the basic theme in terminal to a customized one. The colour issue I'm having with incompatible colours is with hlsearch. Is there a way to change the colour of the highlighted ...
7
votes
1answer
5k views

Vundle - Plugins installed but not loading

I've installed vundle on my ubuntu box but when I load vim none of the plugins load. My vimrc: runtime! debian.vim set nocompatible " be iMproved, required filetype off "...
0
votes
1answer
896 views

Line length highlighting works correctly in console Vim, not GUI

This question is related to this one. Damian Conway provided a nice snippet for marking excessive line length in his recent OSCON 2013 talk about Vim. highlight ColorColumn ctermbg=magenta call ...