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
0 votes
1 answer
10 views

Focus-follows-mouse in Neovim?

Is it possible to get focus-follows-mouse behavior in terminal Neovim? By focus-follows-mouse, I mean when the mouse pointer is hovered over a window that is not activated, it should be activated as ...
1 vote
1 answer
23 views

How to properly indent inline c++ lambdas?

How can I change the behavior of smart indentation when I write a lambda function? This is what I get right now: auto t = std::thread([]{ std::cerr << "...
  • 113
0 votes
0 answers
38 views

Neovim LSP not using project root configs (tsserver / eslint)

Today I have been setting up neovim on windows 11 (not WSL). I can't get the lsp servers to work. The issue is that nvim isn't loading the projects root tsconfig.json or eslintrc.json file for any ...
0 votes
0 answers
24 views

Want to write Bengali in n(vim)

How can I write bengali in Vim in Linux. I have googled but not getting any way. This is Bengali language. Is there anyone writing Bengali in Vim?
0 votes
0 answers
13 views

Neovim tsserver LSP doesn't show the complete error (missing file info), but vscode does

I have two TypeScript files where I deliberately created the error: Duplicate identifier 'User' by declaring class User two times, one in each file. In vscode, I get the additional information that ...
0 votes
0 answers
15 views

Invalid range error with nvim-dap-ui

I was tinkering with nvim-dap-ui which was working fine, but then all of a sudden I started getting this error Error executing lua callback: ...h/.vim/bundle/nvim-dap-ui/lua/dapui/elements/console....
  • 591
0 votes
1 answer
30 views

Vimtutor in Neovim

Is it possible to run vimtutor in Neovim? I'm learning Vim, but I installed Neovim and would like to run vimtutor in Neovim.
0 votes
1 answer
13 views

E824: Incompatible undo file when opening init.vim

I get this error E824: Incompatible undo file: /root/.cache/nvim/undo/%root%.config%nvim%init.vim Press ENTER or type command to continue when trying to open init.vim. When then pressing ENTER it ...
0 votes
1 answer
18 views

Apt doesn't get the latest Neovim version

I had Neovim v0.4 installed via apt (on Ubuntu). But then I saw there is a newer version and tried to install it following instructions here. Now if I use ./nvim.appimage from ~/.config/nvim folder, ...
0 votes
0 answers
16 views

To whom do I report error "LSP: unable to edit document because not previously opened"?

I have this repeatable error running Neovim 0.8 with dartls. It occurs if I :- open a dart file make a change, eg add a blank line :w to save it immediately :e! on the next change attempt, I get the ...
  • 123
0 votes
2 answers
22 views

How to set all files under a folder to a specified filetype?

I have some zsh function files that I should not add extensions to for the convenience of calling, i.e. my_func instead of my_func.zsh. But this causes an issue that Neovim cannot detect their ...
  • 1,131
0 votes
1 answer
24 views

relative numbers neovim, number colors

I'm trying to add realtive numbers to neovim the only thing I can find is regarding to vim which is "set relativenumber" which doesn't work in my init.lua. Not only that, but I'm trying to ...
0 votes
0 answers
30 views

Neovim `vim.lsp.buf.format{async=true}` cause buffer change?

I am using autocmd BufWritePre to do code format with vim.lsp.buf.format(). It is sync and stuck for seconds. But when I use vim.lsp.buf.format{async=true}. The buffer is been changed. Is there a way ...
1 vote
2 answers
46 views

Vimtex - How to run :VimtexCompile on start using lua

How do I execute :VimtexCompile automatically whenever I open a .tex file? As mentioned in this GitHub thread, this is done in Vimscript via: augroup vimtex_config autocmd User VimtexEventInitPost ...
0 votes
0 answers
34 views

Link cwd of vim with parent shell

Is it possible to link the cwd of vim to the cwd of the shell running it, or change the cwd of the parent shell within vim? I run neovim+tmux with the tmux-resurrect plugin, and it would be nice if I ...
  • 1
2 votes
0 answers
48 views

how do I perform a code action on a visual range in neovim 0.9?

In neovim 0.8, I had the following command mapped vnoremap <leader>a :lua vim.lsp.buf.range_code_action()<cr> which in visual mode, gave me options such as Wrap In Try-Catch/Extract Method ...
  • 123
0 votes
0 answers
34 views

How do I organize imports with `tsserver` using Neovim LSP?

I'm using Neovim 0.9 and lsp-zero to edit Typescript files. tsserver has an organize imports feature. How do I map that back through LSP to a user-defined key? Basically, I'd like to add a new ...
0 votes
0 answers
17 views

Dynamic load plugin when using Neovim?

I want to dynamically load the local plugins when using Neovim. For example, there are some directories ~/plugin1 and ~/plugin2 (they're colorscheme plugins). When using Neovim, I try to add ~/plugin1 ...
0 votes
1 answer
17 views

`Cmd+V`/`Ctrl+V` pasting has an extra new line

In init.vim I have: set clipboard^=unnamed,unnamedplus In order to ensure text is yanked into the system clipboard. In Neovim, I select the lines in line mode (V) and copy them with y: a b c In a ...
0 votes
0 answers
29 views

Why do Neovim builtin colorschemes do this awful fake cursor jump?

I'm using Neovim 0.9 with LSP configured via lsp-zero, as vanilla as I can make it. On every built-in Neovim colorscheme I've tried, the cursor becomes evil when it hits a parentheses/bracket ...
0 votes
1 answer
31 views

How to make the 81st column stand out in Lua?

Like this for Vim, I'm trying to convert (with no success): matchadd('ColorColumn', '\%81v\s*\zs\S', 100) from vimscript to a Lua autocmd: autocmd({'BufRead'}, { pattern = "*", ...
  • 157
0 votes
1 answer
60 views

Is there a popular config for Neovim? [closed]

I found a lot of repositories in Github about init.vim like amix vimrc but I couldn't find anything about init.lua. Do you know some repository? I think many of people still using Vim.
0 votes
0 answers
13 views

How come `pip install cmake` is not enough to build neovim?

I just built neovim from source for the first time on linux (Pop!_OS 22.04 LTS x86_64), and I got stuck for a while on something silly. In the Build prerequisites I saw that CMake was (of course) ...
0 votes
0 answers
29 views

nvim-treesitter not working; throws error E5113

I just installed nvim-treesitter and it throws me this error message when starting nvim: Error detected while processing /home/MYUSERNAME/.local/share/nvim/plugged/nvim-treesitter/plugin/nvim-...
user avatar
1 vote
2 answers
78 views

Enable github copilot in Neovim for shell command editing

I use bash and like to use the built-in command Ctrl xCtrl e to invoke an editor in the shell in order to edit the current line. This creates a temporary file, named /tmp/bash-fc.[Some random ...
0 votes
1 answer
33 views

Getting syntax file to load for typescriptreact files

I am very likely missing something very obvious, for I am very new to the vim world. The effect I intended to achieve was to mimic the Inline Fold extension for vscode using vim's Conceal. In short, I'...
1 vote
1 answer
130 views

lazyvim removal/uninstall guidance

I installed lazyvim and have a bunch of missing things with it so I want to know how do i remove it and go back to just default neovim so I can build it back up from scratch
0 votes
1 answer
17 views

System wide sysinit.vim but in lua

sysinit.vim works like a charm, but I want to fully transit into lua. How file should be called? sysinit.lua doesn't work.
  • 1
0 votes
1 answer
21 views

Do I need to set `:filetype on` myself in Neovim?

As title. I'm a user of Neovim and am trying to learn something very basic. My point is that I don't want to set things that will be enabled by Vim by default. And what's the relation between :...
  • 1,131
0 votes
0 answers
15 views

Abnormal behaviour in LuaSnips

Basically I'm following this guide to writing snippets in neovim using LuaSnips. One of the first steps in the basic configuration is to set some key bindings to jump through the snippet tabstops, ...
  • 123
0 votes
1 answer
49 views

init.lua does not run, silent failure

Trying to set up a new VM, I copied over my dotfiles and they weren't working. I've reduced my init.lua to something very simple. All it has is, vim.opt.tabstop = 2 Yet, when I start up vim, nothing ...
2 votes
1 answer
29 views

Neovim: mapping A-b

I am trying to map <A-b> to <C-left> in insert mode in neovim. When I press <A-b> it just inserts the character 0, but when I start neovim with --clean (so all configurations are ...
  • 23
1 vote
1 answer
46 views

How can we know if we can intall a plugin on both Vim and Neovim?

I find in noevimcraft a list of Neovim plugins Can we install them inside Vim or gVim? It seems that the plugins in vimawsome can be installed on Neovim but not always in Vim. Is that correct? How can ...
1 vote
1 answer
32 views

In Neovim is there a way at nvim level to set priorities to control highlight resolution?

Background: It's possible for multiple highlights to affect the same areas in the buffer and work correctly. For example syntax-related colors usually affect fg (foreground, text glyph) color, ...
  • 2,221
0 votes
1 answer
20 views

Splitting windows

Is there any way I can split the window as illustrated in the image?
0 votes
1 answer
17 views

Prevent message when writing buffer

Whenever I write a file in Neovim, I get a message like this: "config/nvim/lua/config/keymaps.lua" 55L, 2256B Sometimes, this can cause a press ENTER or type command to continue message to ...
0 votes
1 answer
24 views

How to use `syn` in regex match?

I'm trying to follow a link using <CR> in a markdown file. I was giving a look into the native markdown syntax file vim ships with and found a few that use the syn command syntax syn region ...
0 votes
1 answer
153 views

How to include/configure lua_ls on lspconfig?

I am trying to include lua_ls on my lspconfig but I am getting this error [lspconfig] Cannot access configuration for lua_ls. Ensure this server is listed in `server_configurations.md` or added as a ...
  • 149
1 vote
1 answer
77 views

How to install dashboard-nvim with vim-plug?

How to install the dashboard-nvm plugin written in lua with vim-plug? If I want to set some configurations, which file I should modify? I am using init.vim and vim-plug has been installed. The version ...
  • 13
0 votes
1 answer
31 views

Angularls root directory not found

I have the angular language server installed but client doesn't attach when I'm in an angular project because it doesn't have an angular.json in the root (since it is an Nx workspace), which (...
0 votes
1 answer
36 views

How do I get coc.nvim to auto-open?

I installed Plug 'neoclide/coc.nvim', {'branch': 'release'} And now I seem to be able to use <C-n> and <C-p> to trigger autocomplete menu but it doesn't show up automatically as I type. I ...
  • 249
0 votes
0 answers
18 views

Is there a recommended way to recompute folds every time a buffer is changed in Neovim?

According to the documentation, the only command that recompute folds is the zx command. However, the problem is that zx automatically undoes all manually opened or closed folds. If I have a bunch of ...
  • 101
0 votes
0 answers
45 views

LSP server is not starting on vue file

I am using neovim v0.8.3 and using kickstart to configure my setup. I added volar = {} in the mason configuration section. But vue language server is not starting on vue file type. It is working if I ...
0 votes
2 answers
40 views

GNU Octave octave.vim syntax file auto indent not working

Before introducing the octave syntax file in ~/.config/nvim/syntax/octave.vim from here auto-indent worked as expected. After introducing the file, the syntax coloring works, but the auto-indentation ...
0 votes
0 answers
14 views

What's the usage of jobresize?

As title. I'm learning Neovim's terminal-emulator related API. To explain the problem I need to show you the code first. I have a Lua script like this: local win = vim.api.nvim_get_current_win() local ...
  • 1,131
0 votes
1 answer
62 views

Setup Telescope to save and close all buffers, when opening a new file

I'm following a Neovim tutorial on LaraCasts from Jess Archer, setting up Neovim. I've used Vim for a while, but I'm new with Neovim. You can see Jess Archers dotfiles here: Jess Archers Dotfiles. I ...
  • 385
0 votes
1 answer
19 views

Working with multiple git branches of Neovim config

I am working with multiple NVim configs through multiple git branches but it appears to be broken like it doesn't update the config after I switch branch and restart Neovim. Restarting my computer ...
0 votes
0 answers
13 views

Check if cursor is inside a pair of quotes

What I'm looking for is basically a programmatic version of vi", va', etc. Say my cursor is at |: function_call(arg, "stri|") I want to be able to find the location/range of the quote ...
0 votes
1 answer
24 views

Why is my AppData folder not indexed by Telescope and how can I fix it simply?

I could not find help with Google nor ChatGPT. Maybe there's something wrong with my telescope config?
2 votes
1 answer
176 views

Icons are not showing in nvim-tree

Unfortunately, I am not able to make the nvim-tree plugin working for me. I installed the nvim-web-devicons as recommended, google a lot but can't find a solution. Please find a screenshot and my init....
  • 123

1
2 3 4 5
26