Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [neovim]

A project that seeks to refactor Vim. Use this tag for questions specifically regarding Neovim-only features (i.e. features not found in Vim and other Vi-like editors).

0
votes
1answer
22 views

How can I make Vimscript check if the current line has a comment?

I want to make a Python ftplugin (but other filetypes will also have this option) where, if the previous line has a comment that starts with #, the next line can be commented via <Shift><CR&...
4
votes
2answers
29 views

Command works in ex mode but not during init (call)

When I run this command in ex mode it works without a problem: :call deoplete#custom#source('ultisnips', 'rank', 1000) However, when I put it in my vimrc I get an error: Error detected while ...
0
votes
1answer
20 views

Why buffer tab plugin not work with Neovim 0.4

I installed the latest Neovim 0.4 from scratch, install 'vim-plug', then add only 4 lines to my init.vim: call plug#begin('d:/neovim/nvim/plugged') Plug 'ap/vim-buftabline' set hidden call plug#end() ...
0
votes
1answer
25 views

Setting $XDG_CONFIG_HOME

My current nvim is in ~/AppData/Local/ and I want to drag it out just one directory below $HOME. How can I set $XDG_CONFIG_HOME, and can it be done via Neovim?
0
votes
1answer
20 views

vim looks different when i launch it via the terminal

I'm using NVIM 0.2.2. When I launch it from the terminal, the color scheme of the terminal affects it's look. And when I launch it from the search menu, it works just fine What makes it behaves that ...
0
votes
0answers
38 views

weird characters on executing shell commands [closed]

MacOS: 10.14.3 Python: 3.7.2 Pynvim: 0.3.2 neovim started with: nvim -u None
0
votes
1answer
27 views

Paste mode sometimes inserting “<Paste>”

Sometimes when I paste (via cmd+v) some text into neovim, it inserts <Paste> at the bottom, i.e: This was pasted and I got some bonus letters <Paste> I can't figure where this text comes ...
0
votes
0answers
14 views

How does (neo)vim set $PATH for system(['command'])

When I want to call an external program, I have the option of spawning a shell or not. system('my command') will spawn a shell (executing your .bashrc/etc and all it seems). system(['my command']) ...
3
votes
1answer
40 views

jobstart callback wont assign variable outside of function

I have a job I want to run in the background of vim, and update my status line with the periodic results of that job. I'm able to setup the timer, call the external job and get my response back. I'm ...
0
votes
0answers
22 views

Configure Denite to Open File in New Window

Below is my configuration for denite. When I select a file from the denite buffer, the file is opened in the preview split window rather than a new window. How can I configure denite to open the ...
1
vote
1answer
42 views

Have a buffer show a “state mark”

I'm trying to to have a visible mark depicting the "state" the buffer is at. A "state" is nothing more but a function that sets or unsets some keymapings that should be easily arbitrarily turned on ...
0
votes
0answers
50 views

2-pane layout on vim for writing (with narrowing fuction, goyo, and outlining)

Is it possible to get a layout like this using only vim? Desired functionalities: A) 2 pane layout like VOoM B) Narrowed region of the whole document on 2nd (right) panel with formatted like ...
0
votes
0answers
18 views

How to limit a key binding to a single key

I'm having trouble putting to words what I'm looking for, please mark as duplicate if appropriate I have a key binding that launches a search based on a fuzzy finder (specifically bindings to fzf and ...
0
votes
0answers
21 views

Can not use mouse to switch window and resize window on Windows with cmder

I am using Neovim on Windows with Cmder terminal. Everything works quite well except that it seems that I can not switch windows and resize window using my mouse even though I have set mouse=a in my ...
0
votes
0answers
19 views

<localleader> not working in .tex files, but working for the other filetypes

I use vimtex, latexmk and neovim in order to edit .tex files in Vim, but for some reason my local leader does not work in .tex files, though the leader works and the local leader works for other ...
1
vote
0answers
21 views

Copy/paste across terminals in nvim? [duplicate]

How do you copy/paste a piece of text across different terminals in nvim (neovim)?
0
votes
3answers
81 views

Nvim can not detect focus change inside tmux sessions

I use the following setting for automatic line number toggle. augroup numbertoggle autocmd! autocmd BufEnter,FocusGained,InsertLeave * set relativenumber autocmd BufLeave,FocusLost,InsertEnter ...
0
votes
0answers
18 views

How to add nvim to launchpad in Ubuntu?

I'd like to add NeoVim to the launchpad in Ubuntu 18.04. When I open nvim in Ubuntu, it just opens a terminal with nvim running in it. If I added it to the favorites (i.e., the lauchpad), only the ...
0
votes
0answers
60 views

Jinja html templates formatting with ALE and Prettier in Vim

I am using NVIM v0.3.2-208-g2841e89 on Ubuntu 16.04 LTS and using ALE as my Linting Engine plugin. I am having issue with formatting for jinja template html files with prettier. The html files which ...
0
votes
1answer
36 views

Start a new terminal instance if window splitting was initiated from a terminal buffer

When I'm in the terminal and I press CTRL + w + s the screen is split vertically and the terminal buffer is showed twice. Then I have to do :terminal if I want an independent instance. Typing ...
1
vote
1answer
37 views

updating running neovim's setting `background` using a terminal response

On my laptop, I frequently swap between a dark and a bright colorscheme for my terminal. I do this by symlinking its configuration file and asking it (termite) to read it without closing using killall ...
1
vote
0answers
30 views

Integrating ranger into neovim

I am trying to get ranger working inside neovim in a sensible way. The official vim plugin provided by ranger works perfectly in ordinary vim: <Leader>r launches ranger in full screen, q exits ...
0
votes
1answer
39 views

execute 'Goyo' on loading pandoc document

It seems like running the Goyo command (a distraction free editing plugin) on loading a pandoc document should be really simple, but execute "Goyo" in .config/nvim/ftplugin/pandoc.vim leads the ...
0
votes
1answer
46 views

Prevent colorscheme from changing background color

I've got a sick terminal colorscheme, and i'm using vim-one colorscheme for neovim, what i'd like to do is stop it from changing the background color (since i like my terminals background color more) ...
1
vote
0answers
36 views

Subscribe to a buffer event in a lua plugin

I want to write a plugin that will watch a buffer for changes and execute different functions depending on the change. I know I can use nvim_buf_attach() to subscribe to buffer events, but they are ...
2
votes
1answer
35 views

Can Neovim API get the text in command input area?

I'm developing a GUI client of Neovim, and looking for the way to get the text in command input area using msgpack-rpc. I mean that the 'text in command input area' is the bottom of Neovim window. (...
0
votes
1answer
57 views

mapping does not work even if I have set it up in config file

I am using Neovim on Windows using Cmder console emulator. I find that using [NUM]<Ctrl-6> to change to buffer [NUM] does not work on Windows. Following discussions here. I have set up a mapping:...
0
votes
1answer
127 views

FZF --preview in Vim returns zsh shell error

I have been trying out FZF with Neovim. I installed it via a nvim plugin package manager. I have not installed it for the command line. When trying to see file previews :FZF --preview="head -$LINES {}...
0
votes
2answers
58 views

How do I clear Neovim window after exiting Neovim on Window 10

On Linux, when I exit Neovim, the content in the Neovim window is cleared. But on Windows 10, when I exit Neovim, the content is still shown and is not cleared, leaving a lot of empty space (see image ...
1
vote
2answers
46 views

Press and hold 'x' and delete just until the cursor

Is it possible to press and hold the 'x' and just delete all characters after the cursor? currently when I hold the 'x' and all the characters after the cursor were deleted, it also deletes characters ...
0
votes
1answer
49 views

How to make vim/nvim to not show the “[Process exited {num}]” when quitting a term?

When quitting the terminal it always shows the [Process exited 2], how can I disable it so that when I quit the terminal buffer should just close silently?
1
vote
1answer
65 views

How to move to parent directory with LeaderF?

When I'm browsing folders in LeaderF is there a way to move to the parent folder? Background: I'm building a vim (Neovim) profile and looking at file/buffer explorers, and LeaderF seems useful. (I've ...
0
votes
1answer
100 views

Change working directory color in NERDTree

Is there any ways to change the font color and background of the working directory as seen in Sublime text? Sublime Text Neovim with NERDTree
1
vote
0answers
125 views

(Solved-ish) neovim: Don't close :terminal buffer after process exit

In Vim, when I run, for example, :terminal python3, and, when I'm done, exit python, the terminal window stays open as a readonly buffer, which I can inspect freely. In Neovim, I always get "[Process ...
1
vote
2answers
87 views

set rtp in a function does not work

I have the following configuration for OCaml development which works fine: " --------------- OCaml ----------------------------- " Merlin let g:opamshare = substitute(system('opam config var share'),'...
0
votes
1answer
107 views

Has nvim ever worked on windows for anyone?

Neovim from the command line works great in Linux, and I have been using it as a drop in replacement for vim. However, I am forced to work with windows (7) at my workplace. I am using vim8 which ...
0
votes
0answers
40 views

Cause of random hangs

Randomly, my nvim will hang. Generally, it seems to happen in command mode. The latest one has hung with: :set paste! paste? On the status line. I have map <F2> :set paste! paste?<CR> ...
0
votes
1answer
22 views

Read the first line of the current file to process it in a command (Emulating %TeX root)

Currently I have the line :nnoremap <leader>c :w<CR>:!arara %<CR><CR> in my $MYVIMRC. If I press <leader>c, it will save the current file and run the command arara on ...
1
vote
0answers
51 views

How do I get neovim to automatically return to normal mode when idle?

This works fine in vim 8: autocmd CursorHoldI * stopinsert After about 5 seconds or so of inactivity in insert mode it automatically returns to normal mode. However, in neovim I use the deoplete ...
1
vote
0answers
43 views

Using pathogen, will allow me to exploit neovim capabilities when developing a plugin?

I just finished reading Learn Vimscript the Hard Way, and I am working right now with neovim And I had a bulky config file with a lot of stuff, that really slowed down vim, when I was handling heavy ...
1
vote
0answers
33 views

Odd langmap behavior with multi-key bindings

I'm getting some odd behavior from langmap. With set langmap=hjki;ihjk inoremap k u works as expected, inoremap jk u maps to ji, inoremap kik u maps to khi. When I say 'maps' I mean that's ...
0
votes
1answer
55 views

Neovim - Run a forward command with python

I need some help with writing a python plugin. I know how to create a plugin but I can't find a way to run a forward or any normal mode stuff. I know I can run commands like echo with self.vim....
1
vote
0answers
23 views

neovim: exit code for jobs terminated by jobstop

When I call jobstop on a running script waiting for input, the on_exit callback is invoked. But the exit code is always 0. Is this the correct behavior? According to :h jobstop it should be killed ...
1
vote
0answers
158 views

NeoVim: colorscheme won't work in init.vim; requires command to be typed

I'm new to NeoVim and just getting started. My init.vim file under NeoVim\share\nvim\runtime\plugin\init.vim successfully sets everything except for the colorscheme and background. As seen in the ...
2
votes
2answers
436 views

Conditional window split

I have line to split window at start: au VimEnter * vsplit But sometimes it's annoying because I'm opening vim in small terminal, in this case I'd like to not split my window. I've tried this ...
1
vote
0answers
143 views

Neovim freezes with FZF

I currently use 'junegunn/fzf.vim', along with the homebrew version of fzf in the command line to search within projects. My setup uses Neovim and Tmux, and I'm getting intermittent freezing when ...
1
vote
1answer
126 views

How to remove entries from v:oldfiles list in neovim

I renamed a big folder that contains a lot of files I recently edited. After changing the name, my neovim's v:oldfiles list contains the old names that is no longer accessible. How can I clean the ...
2
votes
1answer
104 views

vim suddenly stops indenting and uses tabs instead of spaces

every now and then my neovim just stops the correct indenting and i have to restart the session. Besides the indenting, some plugins seem to stop working as well as some built in function like the o ...
1
vote
0answers
182 views

Neovim not showing correct background color

I'm running neovim from a uxterm on arch linux with the solarized color scheme. The issue is that on scrolling only the characters which are non-whitespace are displaying the correct background. ...
1
vote
0answers
39 views

Set different values for non-current and current statuslines

When vim is split into different panes horizontally, each pane has its own statusline. It's easy to highlight the statuslines differently based on current and non-current panes. BUT, I cannot figure ...