All Questions
768
questions
85
votes
5
answers
87k
views
How do I search in all files of my project using VIM?
There are a couple of things I do not yet understand the VIM way.
One of these is searching in a project like so (using VIM in Atom):
I use CtrlP currently for file names, but what about the ...
44
votes
8
answers
29k
views
Is it possible to not display a ~ for blank lines in Vim/Neovim?
Is it possible to not display a ~ for blank lines in Vim?
This confuses Mac Vim's scrollbar, and I quite don't like these tildes.
42
votes
3
answers
7k
views
Clipboard failure in tmux + vim after upgrading to MacOS Sierra
Yesterday, I upgraded to MacOS Sierra and it broke my clipboard functionality in my tmux + neovim setup.
Here is the behavior:
I can use the standard ctrl+c, ctrl+p to copy/paste between system <-...
34
votes
7
answers
22k
views
VIM textwidth has no effect
This feels like a dumb question, but I can't find an answer on the Internet (or in VIM help). I'm using VIM 7.2 on Mac OS X. All I want to do is wrap my lines at 72 characters, but doing
:set ...
31
votes
3
answers
4k
views
Search vim help for subject under cursor
While working with some Vim scripts, I found myself typing
:help {subject}
quite a bit. I want CTRL+] (jump to definition of keyword under cursor) functionality, but instead of running :tag {ident} ...
30
votes
3
answers
8k
views
Working solution for FZF most recent files in Vim?
I have a problem with finding a proper solution for most recently used files with the FZF Vim plugin.
This plugin should have features like:
show files opened in current vim session(like buffers)
...
26
votes
2
answers
1k
views
How to fix buffer in a window in vim?
Can I fix a buffer so that the only way to remove it from vim window is closing it?
For instance, I'm using the NERDtree plugin, which displays the filesystem in a vim window. Sometimes I forget to ...
23
votes
7
answers
19k
views
Neovim colorscheme does not look right when using nvim inside tmux
I'm trying to use vim-material theme from https://github.com/kaicataldo/material.vim
Below is what happens when i run neovim in tmux
Below is what it should look like
What i've tried so far:
in my ...
22
votes
3
answers
17k
views
How do you source neovim config file without restarting nvim?
Is there a way to source the ~/.config/nvim/init.vim file from within nvim?
With vanilla vim you can source .vimrc with :so % : Is there an equivalent method do with similarly in neovim?
21
votes
4
answers
32k
views
NeoVIm does not automatically load ~/.nvimrc file
I was looking to get into learning a text editor for programming. However, I've quickly run into a little snag that I can't seem to find a solution to.
I have modified my /home/user/.nvimrc file to ...
20
votes
3
answers
9k
views
Coc.nvim how to disable auto complete suggestions in markdown files?
I am trying to setup Neovim with Coc for writing markdown. I have Coc working with javascript and other file types.
What I am trying to do is disable the autocomplete suggestions only for markdown ...
19
votes
3
answers
30k
views
Setting autoindentation to spaces in neovim?
I was wondering how I could set the autoindentation to four spaces upon startup in neovim, because I use spaces for indentation.
Thanks in advance.
19
votes
8
answers
9k
views
How can I source files relative to file?
I'm trying to split my vimrc up into multiple files - init.vim, keybindings.vim, ui.vim, etc. - but I can't get Vim to source files relative to init.vim (it instead sources relative to where I launch ...
14
votes
1
answer
2k
views
Vim: How to open new vertical split for file under cursor
I know gf opens the file under cursor, and CTRL-w f opens the file under cursor in a new split window.
I'm probably being greedy but, how do you open it in a new vertical window?
14
votes
2
answers
3k
views
Open vim (or editor of your choice) in nodejs REPL editor mode
As of nodejs 6.6.0, when using the nodejs REPL you can enter multiline text in the terminal with:
.editor
I would like the nodejs REPL to open an instance of vim (in the same manner that git does ...
13
votes
2
answers
12k
views
How to use nvim command if neovim is installed using appimage?
I have installed nvim using AppImage mentioned as below
curl -LO https://github.com/neovim/neovim/releases/download/nightly/nvim.appimage
chmod u+x nvim.appimage
./nvim.appimage
if i use nvim test,...
13
votes
1
answer
4k
views
Open file in a running nvim-qt instance
I want to open new files from the command line on Windows in a single nvim-qt instance that is already open.
I know the existence of the --server option, but how do I know the IP or the socket name ...
12
votes
1
answer
27k
views
What is set mouse = a for in nvim?
I'm not sure I can ask this question, but I can't find information about what mouse = a is for, I just find that it can no longer be copied or pasted with "ctrl + c" and "ctrl + v",...
12
votes
1
answer
2k
views
VIM undo: Why does the cursor jump to the wrong position when undoing `undojoin`?
EDITs:
I've simplified the function and clarified the question.
Original question is still available further down the page.
Crossposted onto vim_dev mailing list:
https://groups.google.com/forum/#!...
10
votes
5
answers
5k
views
Why does Vim highlight all my JSON comments in red?
I've got some comments in a JSON file that were autogenerated by, and unfortunately it seems like vim can't recognize that they're just comments.
They're all red - which one of my plugins is doing ...
9
votes
2
answers
8k
views
Neovim terminal emulator configuration for Windows 10
I am trying to configure Neovim for Windows. One of the key things of this configuration is getting access to the terminal-emulator (it's very comfortable to switch and use the terminal with Vim). But ...
8
votes
5
answers
11k
views
How to disable line numbers in neovim terminal?
I come with a question: How to disable line numbers on neovim terminal?
I tried this:
autocmd BufRead,Filetype term://* set nonu
but this doesn't work.
I use set number relativenumber in init.vim file....
8
votes
7
answers
36k
views
Setting up coc.nvim for python
I have installed coc.nvim and extension coc-python(:CocInstall coc-python)
When I opened file I refused of linting and then get error:
[coc.nvim] Jedi error: Traceback (most recent call last): ...
8
votes
2
answers
3k
views
Script to enable double click a file in explorer and launch/run it with a WSL App (Neovim, Vim, etc) within Windows Terminal
I use WSL (Windows Subsystem for Linux).
I have Neovim/Vim/etc installed in WSL, and wish to be able to open a file in explorer, and have it open in say Neovim installed in WSL, within windows ...
8
votes
2
answers
4k
views
Configuring ALE plugin with Pylint
I'm using ALE with Pylint and pylint-django, but I'm not able to configure it. It shows a linter warning while browsing any file within a Django project:
no-member: User class has no member objects ...
8
votes
2
answers
2k
views
Is there a VIM Git timeline?
So far, I am trying to understand how to use :Glog in combination with :Gdiff, to create a nice overview like the git-time-machine plugin for the Atom editor:
The overview exists of 3 windows
On the ...
8
votes
1
answer
13k
views
neovim auto-indentation nuances
I've just switched from vim to neovim. The following vim config settings get the behaviour I want from indentation:
set tabstop=4
set shiftwidth=4
set softtabstop=4
set autoindent
set backspace=indent,...
7
votes
1
answer
29k
views
How to open a terminal in new tab in Neovim with only one command without remap?
Since 2019, Vim introduces a new command called :terminal, which allow user to open terminal inside of Vim.
To open it in a new tab, I have to type two commands:
:tabnew
:terminal
Is there a one-...
7
votes
1
answer
3k
views
Vim Set Option With String Concatenation
I like to do the following in my .vimrc:
if has('nvim')
let g:base_data_folder = $HOME . '/.nvim'
else
let g:base_data_folder = $HOME . '/.vim'
endif
set backupdir = g:base_data_folder . '/...
7
votes
1
answer
6k
views
Open fzf.vim in split instead of floating window
I've just setup Neovim v0.4.4 with fzf.vim (commit) on a new machine running Manjaro using sudo pacman -Sy neovim. Previously (unknown version) the window for FZF has appeared in a split at the bottom ...
7
votes
5
answers
14k
views
How do I make NeoVim my default text/code editor?
Is there a way to make NeoVim as default text/code editor (without any bad side effects) ?Trust me, I looked to lots of StackOverflow question/answers and tried a few things but nothing worked for me.
...
7
votes
2
answers
1k
views
Is there a way of using my .vimrc when doing a git commit?
I have made my .vimrc fitting my needs in a quite cool way and I'm already really used to it. That's why I get always confused when my different shortcut and bindings don't work as they do in the git ...
7
votes
2
answers
6k
views
neovim can not find python correctly because of virtualenv or conda?
I install YouCompleteMe and UltiSnips plugins in my neovim. Normally, everything is ok.
But I am using MiniConda in my python developing, MiniConda is something like virtualenv, I have a virtual ...
6
votes
2
answers
2k
views
Could Someone Provide a Broken down Description for the Vim Command gqip?
My understanding is that the command gqip, when in normal mode, tells vim to format the current paragraph, separated by whitespace, using the formatoptions as rules. But I can't find any information ...
6
votes
2
answers
7k
views
When brew does not have latest package version
How do I force brew to install latest version of neovim (ver 0.5.0) when brew's formula only has 0.4.3?
I have tried:
brew update
brew upgrade neovim
And it says: Warning: neovim 0.4.3 already ...
6
votes
3
answers
3k
views
How to close FZF without select any result in VIM
I use fzf.vim to quickly find files in my projects in neovim.
Sometimes either because I can't find what I'm looking for or because I forgot to do something before open the new file, I need to cancel ...
6
votes
2
answers
550
views
`vi{` increases the visual selection, but can I reduce the visual selection in a similar way?
So if I've got text like:
if answer == 42 { #1
if bugs == 'bunny' { #2
if injury == 'but a scratch' { #3
// do the thing #...
6
votes
2
answers
748
views
Unknown function: elm#FindRootDirectory
I'm getting this error message: Unknown function: elm#FindRootDirectory
When I open an elm-file within neovim.
I'm using ElmCast/elm-vim as a plugin to write elm code.
I know I could simply remove ...
6
votes
1
answer
3k
views
How to debug `Error while processing function` in `vim` and `nvim`?
TL;DR
How to find where exactly vim or nvim error started (which file?) when I'm interested in fixing the actual issue and not just removing the bad plugin? Anything better than strace and guesswork ...
6
votes
2
answers
3k
views
How to search hidden directories/files with path=.,** and :find?
I have been using junegunn/fzf.vim to quickly find (hidden and non-hidden) files in vim. I just found out that it's also possible to set
path=.,**
and use :find some-file to achieve pretty much the ...
6
votes
1
answer
5k
views
How to page-up / page-down through vim terminal
I am new user to Vim and I want to use vim's embedded terminal (called by :term). Unfortunately, I cannot use this terminal as I want to. The Shift + PageUp / Shift + PageDown duo (to move up and down ...
6
votes
1
answer
1k
views
Vim fugitive with neovim terminal emulator
I recently switched from vim to neovim, installing the vim-fugitive plugin. Before, running :Git rebase -i in vim bought up the interactive rebase window in a vim window which I could edit as I needed ...
6
votes
1
answer
2k
views
Manual completion with Ctrl-N in Deoplete
I installed deoplete and it works for me, however by default it opens a pop-up window whenever you type something. This is not desirable. I want pop-up to only show when I hit Ctrl+N. So I disable ...
6
votes
0
answers
507
views
Vim: temporary normal mode while holding Alt in insert mode
I wonder if there's a way to make the Alt (or another key) work like Ctrl-o, but for as long as the key is pressed. For example, if you're in insert mode and want to move 10 lines down and 2 words ...
5
votes
3
answers
4k
views
Is there a Vim motion command that put cursor at beginning of current word?
Let's suppose I have the cursor located as depicted on next image
Pressing b in normal mode I can go to the start of the word.
Great!
If I move cursor to 1 like
and press b we have
Question:
Is ...
5
votes
3
answers
14k
views
Debugging C++ in (Neo)vim
I just switched from windows 10 to arch linux
I want to use (Neo)Vim as my code editor
I've sitted up autocomplition
and Fuzzy finder
But I have no idea how to debug in (Neo)Vim
Any helps!
5
votes
1
answer
6k
views
Base16 & neovim. How to use consistent colors in both linux VT and X terminal?
Recently, I've configured my shell using base16 color scheme using this script: https://github.com/chriskempson/base16-shell/blob/master/scripts/base16-default-dark.sh. And Neovim's color scheme using:...
5
votes
1
answer
5k
views
How do I enable Ruby syntax highlighting in Neovim?
I'm a new user of Neovim and trying to figure out how to enable syntax highlighting for Ruby.
What config should i edit?
edit:
This is my current config:
➜ ~ cat ~/.nvimrc
filetype plugin ...
5
votes
1
answer
1k
views
Why is Nvim default settings overriding my ftplugin settings? (Neovim)
When I open a PHP file, Neovim sets nosmartindent and indentexpr=GetPhpIndent().
This is a bummer, because GetPhpIndent() is completely broken and makes the editing experience a nightmare where I have ...
5
votes
1
answer
17k
views
Neovim: Relative config file(init.vim) location
I'm moving from vim to neovim, and my problem is that I need to carry it on portable USB sticks.
So I need to read config files from relative path. I used $VIM/_vimrc for this purpose on original vim, ...