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).

Filter by
Sorted by
Tagged with
3
votes
1answer
42 views

Remapping motion keys [duplicate]

I recently found the awesome plugin named CamelCaseMotion which is awesome. I used their suggested mappings in my .vimrc for the plugin like this: map <silent> w <Plug>CamelCaseMotion_w ...
1
vote
2answers
59 views

Insert text in the middle of a string vimscript

I'm trying to make a function in vimscript that converts markdown to html files using pandoc and putting that converted file in a specified directory. Currently i am putting the file in a directory ...
0
votes
0answers
35 views

Correct way to setup python version for coc

I want to set PYTHONPATH and python interpreter according to projects I am working on. I am working both on projects involving python 2.0, and ones involving python 3.0. There is the concept of ...
2
votes
0answers
21 views

How do I setup Mypy with Neomake

I'm trying to use Mypy with Neomake, but without success. I am currently using flake8 with Neomake, and it works seamlessly, e.g.: def foo(bar): return 1 foo(1) > E305 expected 2 blank lines ...
2
votes
1answer
21 views

How do I configure the parameters that ALE sends to prettier for ruby?

Note: this is a neovim question, not stock vim I have both rbprettier and prettier with the ruby plugin installed on my system. If I pipe a Ruby file into rbprettier, or if I pipe it into prettier --...
1
vote
0answers
26 views

How to externally trigger [neo]vim to reload an edited file?

I have a file, /tmp/file.txt that is being edited by vim (or neovim), as well as some other external process. I wish the external app to notify vim, in such a way that vim takes that notification to ...
2
votes
2answers
77 views

Getting an RGB color from highlight group

In putting together and addon for blender to integrate neovim. Where I'm at with it, github colo imported to blender text editor from nvim_gtk One component is grabbing the current colorscheme of a ...
1
vote
2answers
130 views

How to follow the output of a command in a terminal window

I recently decided to give a try at neovim and one thing is bothering me: I use a terminal window to run my code watcher i.e. a never ending command which outputs new lines each time I write a buffer....
1
vote
0answers
21 views

Where can I find good indentation file for lex filetype?

I checked and found only a syntax file for lex filetypes in /usr/share/nvim/runtime/syntax, but found no indent file in /usr/share/nvim/runtime/indent I want my lex files to be properly indented; one ...
2
votes
2answers
173 views

Does NeoVim really need plugins in 2019?

I've been using Vim with vim-plug, yiang-miao/auto-pairs and youcompleteme for a time now, and I really love it; but a friend recently recommended me NeoVim, and it seems it's more polished since it's ...
0
votes
1answer
40 views

Change saved session's working directory

I have a neovim session saved using :mks which by default saves to a subdirectory in my project ~/project/subdir/Session.vim. I want it to save to ~/project/Session.vim, which I can do by running :cd ...
0
votes
1answer
52 views

Neovim-Qt: environment variable TERM not set

Running :checkhealth in NeoVim-Qt (v0.3.5) I get the following report on terminal: ERROR: command failed: infocmp -L infocmp: environment variable TERM not set How can I set the environment variable ...
5
votes
2answers
160 views

How to make insert mode mapping count as multiple undos?

I have the following mappings: nnoremap # /___<CR>ciw imap # <Esc>:w<CR><Esc># And the following file that I am editing: foo ___ goo ___ hoo ___ The idea is that I start at ...
1
vote
1answer
21 views

How to wrap a command which can handle a text object?

The scenario is that the plugin I use (iron.nvim) has a mapping crt which handle text objects. Ultimately, this mapping is based on a command <Plug>(iron-send-motion). I would like to create a ...
0
votes
0answers
42 views

My cursor is changed after “df” [duplicate]

I have the following to change my cursor from a block into an underline: set guicursor=a:hor20-Cursor Whenever I run df to delete a range, my cursor is changed back to a block. I have to source my ...
2
votes
1answer
55 views

Where can I find color settings used by Vim and NeoVim?

I've been using dotfiles created by other people to setup Vim. Recently I decided to create my own config and investigate what's NeoVim about. I'm using default OSX Terminal.app with zsh shell (I've ...
1
vote
1answer
78 views

How to get rid of inline linting errors?

I ran PlugUpdate recently and somehow all the Ale linter errors started popping up right in the buffer at the end of the line. It used to just put signs on the left side for the problematic line and ...
0
votes
0answers
63 views

How to make vim theme looks exactly as on screenshot

I've tried dozens of different themes but always get wrong coloring. For example: This is how vim-afterglow should look with LaTeX code. This is mine screenshot: This is example for Python. And ...
2
votes
1answer
76 views

why doesn't this autocmd take effect for neovim?

I am writing an autocmd which will warn me if the file opened is not in UTF-8 format. This is what I have got: augroup non_utf8_file autocmd! autocmd BufRead * if &fileencoding != 'utf-8' ...
1
vote
0answers
28 views

Using ! (filter command) just to see the terminal behind vim

I recently started a transition from vim to neovim and one of the things that I noticed that changed is that typing :! doesn't do anything in neovim but in vim it displays the content of the terminal ...
1
vote
2answers
60 views

How can I focus on one vimsplit fullscreen?

Say I've got three splits open with code in, and I suddenly want to make the one I'm in fullscreen, temporarily. How can I do that?
2
votes
1answer
38 views

Difference between searching and substituting pattern matching

I have a string in a JSON file which is repeated with different values for chance. I want to replace all of these blocks by moving the miss chance out of the attack array and into a separate property. ...
0
votes
1answer
99 views

How can I emulate :shell command in Neovim?

There is no :shell command in neovim. :terminal opens a shell without previous output, while :shell contains all the output of the parent shell and all previous shells. Is there any way to emulate :...
1
vote
1answer
46 views

NeoVim: Single-Line Comments Also Format the Next Line [duplicate]

So, I started using NeoVim a little while ago and discovered a rather annoying quirk when using C++-style single-line comments // in source code of any language. Specifically, when you create a new ...
0
votes
0answers
35 views

Automatically inserting predefined strings to terminal buffer

When I compile any code file in vim, I use a specific mapping to open the terminal buffer and get into insert mode, but this requires me to be aware of the (potentially long and complicated) file name....
1
vote
3answers
71 views

How to setup spelling for same words in different languages?

I use vim for prose and and code, and when it comes to prose I use spelling a lot to help me out. I have it set up and already, and I'm already working with z=, zg, zw, [s , and ]s to work with ...
0
votes
0answers
59 views

Ctrlp and neovim

I recently switched to neovim. I was using CtrlP plugin. But whenever I fire it up on neovim, it starts spitting out weird symbols which makes my tmux glitch. I have added the following to my init.vim ...
1
vote
2answers
171 views

neovim key remap specific to terminal buffer

I have been using nvim terminal mode to learn python and I want to have Ctrl-C break the python script from the terminal window even when I am not in insert mode. However, I also want Ctrl-C in my ...
1
vote
1answer
38 views

Is it possible to obtain status line strings?

I am developing a neovim client using RPC, and trying to get all status line texts shown in below figure. Are there any ways to get them? I have already tried using execute function and the ...
0
votes
0answers
83 views

UltiSnips: snippets not expanding

This is a noob question. I just installed UltiSnip to make use of the TeX snippets. Here is the relevant part of my init.vim: " Specify a directory for plugins (powered by vim-plug) call plug#begin('~...
2
votes
1answer
135 views

Neovim spellcheck: all the words highlighted as misspelled

I've been trying to set up spell checking in neovim. init.vim: setlocal spell spelllang=ru_ru First time it downloaded ru.utf-8.spl and ru.utf-8.sug, just as it probably should. Unfortunately, as ...
0
votes
1answer
26 views

nnoremap conflicts with i_CTRL-O

I added two normal mode mappings so that the cursor doesn't move when changing case nnoremap gUiw m0gUiw`0 nnoremap guiw m0guiw`0 Recently I had to uppercase a word and I tried like this: ...
0
votes
1answer
29 views

How to subscribe event by using nvim_subscribe

I am trying to handle events of nvim using nvim_subscribe() API via RPC. For instance, calling nvim_subscribe('CmdLineEnter'). I am not sure the specification of this API exactly, but I imagine that ...
0
votes
0answers
186 views

How to hide terminal buffer without closing it?

I want to make toggleable window with terminal buffer similar to every IDE terminal feature. Currently i have mapped: noremap <F4> :botright 8split term://bash<CR> tnoremap <F4> &...
0
votes
1answer
120 views

How to keep the neovim terminal buffer in the buffer list even after it being hidden

My problem is similar to, if not same as, this issues. But I can't follow what they're talking about. The following steps are necessary to reproduce my problems: :sp :term :wincmd w :wincmd o :ls ...
1
vote
2answers
310 views

Neovim with split integrated terminal / REPL

Other editors and IDEs, such as VSCode and RStudio, have an integrated console/terminal/REPL with the following characteristics: They open in a split window. The file we’re working on is visible at ...
1
vote
1answer
64 views

Importing project-specific rc files in Neovim

Vim probably did this by default, whenever I invoke files from a project that has its own .vimrcs it's auto-sourced. Neovim, however, doesn't import vimrcs. How can I make Neovim scan and use project-...
1
vote
0answers
38 views

Sharing a copy register between vim on different machines?

The image below shows two terminals. Both are running vim instances on remote machines (ssh and a serial connection through an UART cable). Vim's on those machines don't have a way to access the ...
2
votes
2answers
56 views

How to test for :terminal support?

I have neovim 0.3.4 installed which means I can run the :terminal command, however, doing :echo has('terminal') shows 0. So, I wonder if there is any other way I can test for its support because all ...
0
votes
1answer
33 views

How to show the left-hand side of insert mode mappings while invoking them in Neovim

Much like what was asked in this question: I want Neovim to show what I type, and keep recognising it as a mapping in progress even if I use Backspace or Delete. This is actually a very useful ...
0
votes
1answer
38 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
78 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
44 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
221 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
51 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 ...
2
votes
1answer
92 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
38 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
85 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 ...
1
vote
0answers
182 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
67 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 ...