Skip to main content

Questions tagged [vimrc]

Vim's configuration file.

Filter by
Sorted by
Tagged with
1 vote
3 answers
291 views

Disable settings for files without extensions

I want to disable certain settings (like line numbers) when vim opens files that don't have an extension. I have set number in my .vimrc, and I know that I could disable this for example for markdown ...
liakoyras's user avatar
  • 111
0 votes
1 answer
159 views

vim is ignoring configurations

Vim is just not applying some configuration statements. This behaivior started after I installed a plugin to it, and updated MacOS (that shouldn't be related to each other !?). One example is ...
26035's user avatar
  • 1
1 vote
1 answer
440 views

How can I make neovim display the "search hit BOTTOM, continuing at TOP" message like vim?

Unlike vim, neovim does not display the search hit BOTTOM message when searching repeatedly for a string. Tested with neovim 0.6.1 on ubuntu, no init.vim and no pluins, and editing /etc/ssh/ssh_config ...
patraulea's user avatar
  • 411
1 vote
0 answers
731 views

How to delete selected text in neovim?

I have xnoremap <BS> "_di this keymap in my neovim config. But when I select a text in visual mode and press backspace to delete the text, the text deletes and gets copied to my clipboard. ...
Sunlight's user avatar
0 votes
1 answer
64 views

Location of .vimrc sourced by vim editor in mutt

I am having trouble trying to customize the vim editor that mutt opens while composing and reading emails. While composing an email, mutt opens a vim text editor. The name of this file/buffer seems to ...
Tryer's user avatar
  • 111
4 votes
1 answer
486 views

Vim NERDTree increases the command line size and doesn't shrink it back

I am using MacVim 9.0 with NERDTree. Some commands in the NERDTree cause the command line to increase in height to display the full command description. (For example, pressing m in the NERDTree window,...
Tim's user avatar
  • 1,727
0 votes
1 answer
91 views

Can't convert vim macro text to normal characters

I'm trying to save a vim macro that I wrote into my .vimrc file. I successfully recorded the macro into register s, the contents of which display as: .,.s/S:/\&AHOMW€kbW€kbE/:.,.s/\\/\//g'€kb0 I ...
fireblood's user avatar
  • 375
0 votes
1 answer
636 views

Mapping redo in insert mode VIM

How to remap a redo shortcut (Ctrl-R in normal) to Ctrl-Shift-Z in insert mode? It would be helpful since I mapped undo to Ctrl-Z like this: nnoremap <c-z> :u<CR> vnoremap <c-z> :u&...
Eldar's user avatar
  • 121
2 votes
1 answer
724 views

How to start Vim with a clean jumplist

I want Vim to start up with a clean jumplist. I don't want to go back to old files i edited in another session when I press CTRL-O. The jumplist is stored in .viminfo and I can't get it to disappear ...
Daniel Ohlsson's user avatar
0 votes
1 answer
408 views

How do I change Vim splitting key-mapping?

I have recently started learning Vim, and I don't like the default key-mapping of splitting windows in Vim. That is, I don't like to enter C-w and then S for horizontal and v for vertical, and moving ...
LordRishav's user avatar
0 votes
1 answer
88 views

Remapping default bindings vim

When I press ctrl+h in insert mode vim cuts character to the left. I have tried: noremap h <NOP> inoremap h <NOP> noremap <C-h> <NOP> inoremap <C-h> <NOP> to ...
beardeadclown's user avatar
1 vote
2 answers
947 views

How do I move all of my dotfiles to a custom directory?

I'm a Mac user and I was wondering if there was a way to put all of my dotfiles to a .config folder to store all of them (something analogue to XDG Directories on Linux). I was trying to set up a ....
baggiponte's user avatar
1 vote
2 answers
2k views

How do I resolve a keybinding conflict with coc for vim?

Just as a preface, I'm not a programmer, but I've written a bit of shell to automate things. This is on MacOS Mojave, but it shouldn't make too big of a difference since neovim's configs should carry ...
wildwestrom's user avatar
2 votes
1 answer
615 views

Solarized leaving red highlighting at the end of lines in vim

I'm using vim with the solarized dark color scheme within the Windows Subsystem for Linux. Solarized looks great except for one strange feature. When I scroll down in a vim file and then scroll back ...
Harry Williams's user avatar
3 votes
1 answer
436 views

My VIM basic imap mappings have no effect

Good afternoon, I am struggling with Vim mappings. I would like to practice over very basic ones such as "replace a-s with b-s", or "replace ù with /", but I do not succeed. Here are my trials: :...
Luc's user avatar
  • 33
1 vote
0 answers
317 views

Why Won't Deleting vimrc Reset Vim Settings? (Mac)

I reinstalled Macvim using Homebrew, deleted and reinstalled both the vim folder at /usr/shared/vim and vimrc. When I open text files with vim the settings are the same and any changes I make to the ...
Samuel Nelson's user avatar
0 votes
1 answer
67 views

My Esc+<left arrow> deletes 3 lines in vim

I am somewhat confused as what can be the cause of it. I disabled everythin in vim (replaced .vimrc with a blank file) and still, when I press Esc+left, I delete the 3 lines above my cursor, and with ...
cduguet's user avatar
  • 101
1 vote
1 answer
823 views

my WSL ubuntu vi editor screen is broken when I scroll down

When I scroll down at my vim editor, all of my codes is wrapped with strange boxes. Can I fix it? My .vimrc file: Problem Image:
SunBathe's user avatar
1 vote
0 answers
733 views

Vim - E490: No fold found

I'm having problems folding some lines in a LaTeX. I use the set foldmarker=/*,*/ option in my .vimrc, and is working fine in the main file, but when I change the buffer, in the other file, I can't ...
jcrcx's user avatar
  • 11
0 votes
0 answers
393 views

Unable to include plugins using vimrc . Error for each line of my vimrc

I have installed gVim and trying to have customizations, i.e, including plugins. https://raw.githubusercontent.com/kinbiko/dotfiles/master/vimrc Used multiple plugin managers, but in vain. Error ...
John Hugh's user avatar
2 votes
1 answer
193 views

How to make Vim "repeat search" direction absolute instead of relative?

I am looking for a way to make Vim always go backwards whether I press repeat last , or N and forward when using their pairs ; or n. Currently Vim is using a relative direction which depends on the ...
Nicolas LIENART's user avatar
2 votes
1 answer
2k views

How to move from insert to replace/overtype mode in vim

How can you switch from insert mode to replace/overtype mode in vim? In windows/*nix I just hit the insert key twice (command->insert->replace), but unfortunately i'm stuck on a mac now which doesn't ...
someguypq's user avatar
1 vote
1 answer
274 views

Extending highlight on line number to ALE gutter as well

I have set cursorline enabled, and it works. I'm also using ALE to lint my code, and I have the sign gutter set to show always (g:ale_sign_column_always). However, in filetypes that ALE knows how to ...
ellie's user avatar
  • 13
1 vote
1 answer
361 views

Move cursor by line number when moving through multiple lines (e.g. `5j`), move by display line when moving through a single line (e.g. `j`)

In Vim, I have the following set in order to have ragged right soft-wrapping of lines: set linebreak set wrap When traversing multiple lines at once, an annoying side effect is that 5j will not move ...
John L. Godlee's user avatar
0 votes
1 answer
330 views

Why remapping <End> key to <S-A> causes Vim to behave weird?

nnoremap <End> <S-A> " line comment Pressing End key then produces the desired effect but vim also appends " line comment to the end of the line! Is there any way to kinda let vim ...
iamarkadyt's user avatar
0 votes
1 answer
7k views

How do I set the font in command line vim (vim for windows)?

everything I see says I should use guifont but if I open a console and try to tab complete set gui--- I only see set guicursor Im using command line vim not gui vim. What do I put in vimrc to set ...
user1028270's user avatar
  • 1,045
1 vote
1 answer
479 views

How do I use a custom vimrc file?

I have just started using vim and I find a bunch of vimrc files online. How exactly do I tell vim to use this vimrc as the default vimrc. I know I can copy every time but is there a better way to do ...
user3262922's user avatar
-1 votes
1 answer
2k views

vim error 'E45: 'readonly' option is set' on a file with write permission Debian 9 vim 8.0.707

I wonder why I have the error in title while the edited file have write bit enabled and the good user : # ls -l /etc/hosts -rw-r--r-- 1 root root 693 Nov 15 09:46 /etc/hosts # whoami root Any idea ?...
Mévatlavé Kraspek's user avatar
3 votes
0 answers
2k views

How to set scrolling speed of vim like set mouse=a when mouse=v?

I wonder how it's possible to set scrolling speed. As is, when I scroll with my mouse in command or edit mode, it moves only one line at a time. I prefer to move by example 3 line at a time. (speed ...
Mévatlavé Kraspek's user avatar
0 votes
1 answer
134 views

Vim: Operator pending mode remaps not working

I'm trying to build a vimscript can be used with the Dvorak Simplified Layout. I.e., given that the keys on the keyboard plugged into the computer are laid out in the Dovark Simplified Layout (and the ...
Sergey Nikolayvich's user avatar
0 votes
1 answer
100 views

Mapping a command not the same as writing command in vim terminal

I'm trying to use a mapping in my vimrc to execute a command. The command works if I directly type it into the vim terminal, but when I use the same command it stops typing it after the first space. ...
mildlyAverage's user avatar
0 votes
1 answer
1k views

How to enable both this vim feature: mouse cursor move and paste with middle mouse in same time?

I would like to have two features in VIM Mouse Cursor Movement Paste from global clipboard with middle mouse For the first feature I can set mouse=a and the second mouse=r. Separately these ...
bioinfornatics's user avatar
1 vote
1 answer
305 views

vim is using previous version of vimrc under some circumstances

Funny thing is happening to me on vim: I made some changes to a user's ~/.vimrc in order to customize the status line with a simple function (the changes were made on several saves while I refined the ...
Paolo's user avatar
  • 45
1 vote
0 answers
225 views

Vim session with splits with remote ssh files

I use to use vim session to keep my opened files. I do it remotely, ssh remote machine and do things there. Today I tried to open remote files in local Vim, I mean with netrw: :e scp://user@remoteip/...
KcFnMi's user avatar
  • 604
5 votes
2 answers
1k views

How can I Insert the result of a ".w" evaluation at the end of a line in Vim?

I'd like to be able to evaluate a line of Javascript (or other code) in Vim, and have the result appear in a comment at the end of the line. For example, if I have a file like: console.log(4 + 5); ...
d1pl0mat's user avatar
  • 173
2 votes
2 answers
17k views

How to use gruvbox airline theme?

I'm trying to use the gruvbox airline theme with my gruvbox color scheme but there doesn't seem to be an official airline theme for gruvbox. https://github.com/vim-airline/vim-airline-themes/tree/...
tarabyte's user avatar
  • 2,375
1 vote
1 answer
2k views

how to make vim to have python interactive runtime window

Is it possible to have python live program mode window open in python so we can call program and see the live outcome straightaway instead of jumpout vim to CMD? It is a bit like VisualStudio setup.
NewPy's user avatar
  • 153
1 vote
0 answers
338 views

Issue with vim setup python ide

Found ale lint on git about vim but the display after clone from git is still shown as classic instead of the one shown on: The syntax suggestion is not on as well Do I need to run ale toggle to turn ...
Kalu's user avatar
  • 11
2 votes
2 answers
1k views

Not able to map any keys between F1 to F5 in gvim

I am not able to map any keys between F1 to F5 in gvim through vimrc. However all the keys after F5 are being properly mapped. Here is my vimrc file content. map <F1> :q!<ESC> map <...
Karan Shah's user avatar
-1 votes
1 answer
985 views

How to hide the status lines of other opened buffers in vim?

The image below illustrates the lines or window titles at the bottom: I wonder how to hide the status lines of other opened buffers in vim?
Neo Mosaid's user avatar
1 vote
1 answer
206 views

How can I change certain keywords in vim to all-caps?

How can I change certain keywords in vim to all-caps? I would like to know as I am programming in Fortran and the required style is to have all the intrinsic functions in caps. For example the keyword ...
Matt Ellis's user avatar
0 votes
1 answer
675 views

vim multiple specific mappings

What is the best way to specify multiple modes for a map in vim? I know that nmap x y triggers y on receiving x when in normal mode, imap x y triggers y on receiving x when in insert mode, and so on....
omnesia's user avatar
  • 137
0 votes
1 answer
559 views

vim remove characters from buffer separations

If you look at the screencasts from vimfiler you can see that there's no characters in the separations, some are just a thin line. Where as mine as the default | pipe character. My question is ...
Thermatix's user avatar
  • 253
1 vote
1 answer
323 views

Autocmd ignores mapping?

For convenience I mapped "unindenting" to SHIFT+TAB in my .vimrc: nnoremap <S-Tab> << inoremap <S-Tab> <C-D> This works fine if I use it myself while editing, and so I wanted ...
omnesia's user avatar
  • 137
1 vote
1 answer
1k views

ability to switch between panes has broken in tmux with vim

Ok, so I run vim inside of tmux and recently (today in fact) I suddenly can't use ctrl+hjkl to switch between panes in tmux and vim, instead it just makes the bell sound and refuses to switch. If I ...
Thermatix's user avatar
  • 253
2 votes
1 answer
354 views

Vim mapping for .vimrc only

I know about autocmd FileType <TYPE> inoremap <MAPPING> for files like *.html. But i would like to create some keybinds for within my .vimrc like this: autocmd FileType vimrc inoremap ;...
omnesia's user avatar
  • 137
2 votes
0 answers
584 views

Vim - Detect Caps Lock Status

My question is simple and straightforward! =D In this thread @OsQu... Vim - Is Capslock on? ... says that you can use the Automation Hotkey Scripting (AHK) below to detect the Caps Lock (on/off) ...
Eduardo Lucio's user avatar
0 votes
1 answer
851 views

Vim leader key mapping for multi step copy and paste

When I need to copy and paste large blocks of code from a webpage, I need to do the following one step at a time: :set paste enter Vim insert mode paste clipboard set nopaste enter normal mode I'm ...
Josh's user avatar
  • 792
0 votes
1 answer
5k views

Defining custom command in nvim.init

I am trying to define my custom command in nvim.init (NeoVim) but I've occurred an error. Could be so kind and help me with getting rid of it? Here is a line which I've putted into nvim.init: ...
FieryCod's user avatar
  • 111
1 vote
1 answer
272 views

Fail to add a new word to the "good" list of vim spell checker

I am using the vim spell checker. When I do "zg" (Add word to "good" list) it apparently works. If I save and quit ( with :wq command) and re-open the document all words get reddish indicating that ...
Gabz's user avatar
  • 113

1
2 3 4 5 6