Questions tagged [neovim]
The neovim tag has no usage guidance.
40
questions
0
votes
0
answers
8
views
How can I change the default starting folder for a specific application launched from finder on Mac
I would like to launch the Neovim-qt app and have it default to something other than the root directory ("/") on my MacBook.
On Windows, I can change the default directory from the "...
0
votes
1
answer
12
views
Search and Replace in highlighted text returns Trailing Characters error in neovim
I have a block of code in NeoVim and try to do a search and replace:
CTRL+V Visual mode.
'J' multiple times for a block of lines
':' starts with :'<,'>
add 's/abc/xyz/g
Enter
Result:
Trailing ...
1
vote
2
answers
32
views
How to copy word length in to clipboard?
i have a few words and need to copy word length in to clipboard.
Tried :!wc or g and Gv but don't work
0
votes
0
answers
40
views
Why doesn't this bash/diff command work through Neovim?
I am using WSL bash (Ubuntu distribution).
From Windows command line, this works as expected:
bash -c 'diff test.txt -'
However when running the following through Neovim:
:w !bash -c 'diff % -'
This ...
0
votes
1
answer
65
views
Is there a simple way to review changes before writing file in Neovim on Windows?
I want to review changes I made to my file before I save it. Is it possible to do this, preferably without using vimrc or installing additional software? I'm using Neovim on Windows.
I tried one of ...
0
votes
1
answer
96
views
NeoVim: Switch between sets of open tabs, depending on git branch
When working on multiple different branches in a git repo, I have found myself to want different sets of files opened in different tabs. Is there any plugin or way to essentially "save" the ...
1
vote
1
answer
517
views
Open a new NeoVim window using Windows terminal
I am currently using NeoVim by running it from the Windows terminal (Windows 10), using the nvim command. For the moment, if I type Neovim in the Windows search bar and open the app, it opens in the ...
0
votes
1
answer
96
views
Why neo vim is displaying $ at the very end of line and > at the beginnings of line
Why neovim is displaying these special characters at the beginning and at the end of line?
I have uninstalled and reinstall neovim but this didn't fixed the issue.
How can I fix it?
1
vote
1
answer
198
views
nvim error on :so in Ubuntu WSL2
I have Ubuntu over WSL2 and I was following this video tutorial on how to configure vim. My nvim installation didn't have the .config folder, so I created it and followed the video.
I placed an init....
0
votes
1
answer
53
views
Unusual behoiur in tmux, Tab clears the pane when it's not set to
For some unknown reason in Tmux the 'Tab' key clears the pane I'm in, which is annoying when I use 'Tab' to indent in Neovim and 'Shift Tab' to unindent.
Is there a way to fix this (stop 'Tab' ...
1
vote
2
answers
839
views
In [Neo]Vim, how do I display error messages from an external command used as a filter on the visual selection?
Summary
In [Neo]Vim, if I call an external command on the current visual selection (expecting that command to transform the selected text, which Vim then updates in the buffer), and the command fails ...
0
votes
0
answers
215
views
Change default application for opening certain files to be a commandline application (e.g. neovim/nvim/vim)
For example if I have a .md file in a directory open in file explorer and I open it, it should open within neovim with syntax that generally looks like this:
wt nvim %
wt being windows terminal and % ...
1
vote
0
answers
214
views
Neovim Slow Cursor Blinking
I'm trying to switch from Macvim to Neovim, but running into an issue that I can't figure out. I can't get guicursor to fully work. I say fully work because some of it does, e.g. setting ver25 or ...
2
votes
0
answers
407
views
Easiest way to switch NeoVim Control key shortcuts to command key
tl;dr
Searching for a way to replace all shortcuts in neovim that use the control key with the command key on Mac
--
I just got started in using neovim as my main code editor
However I find hitting ...
0
votes
0
answers
189
views
Neovim cannot find various executables when launched through an applescript
I am using MacOS Monterey and am attempting to create a means through which I can double-click a program file in Finder and have it open in neovim. To do this, I need to launch nvim through an ...
1
vote
0
answers
47
views
Applescript cannot find file that exists
Big picture, I am trying to create an applescript that allows me to open files in neovim from Finder. Though I have found several resources for doing this, none work exactly as-is, so I have to do ...
-1
votes
1
answer
136
views
Move-Item, mv and Get-Command not recognized as internal or external command in Powershell [closed]
Why are this essential commands just not recognized? I am on Windows 11, using the new Terminal app with Powershell. I can't even run Get-Host to get the Powershell version. I am using a terminal ...
1
vote
1
answer
1k
views
Is it that bad to use Homebrew on an outdated macOS?
I had problems on macOS Monterey and had to downgrade back to Catalina due to performance issues (found out it was just my MBP 2016 needing some hardware cleaning, so I'm considering going back to ...
1
vote
0
answers
446
views
How to set neovim's lua module search path?
I found a very useful file browsing plugin: nvim-tree
But I think this plugin can also add a template function to create files using templates.
I'd like to develop this functionality myself, but I'm ...
1
vote
1
answer
230
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 ...
0
votes
1
answer
60
views
How to make neovim automatically convert the parameters of the command into strings?
I want to make a command:
command -nargs=1 Demo lua print <args>
I have the following problem when I execute it:
Demo test
nil
I had to put double quotes around the parameter to make it work:
...
0
votes
1
answer
370
views
Neovim suggestion selection menu
Some menus in the neovim autocomplete suggestion can not be selected and I have no idea how to select them. I tried several keyboard shortcuts, such as Ctrl +P, Ctrl + N, Alt + F, Ctrl + Space + F..., ...
0
votes
0
answers
362
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.
...
6
votes
3
answers
16k
views
Can't install neovim v0.8.0+ on Ubuntu
I can't intstall neovim 0.8.0+ on KDE neon (based on ubuntu). I need neovim 0.8+ for LunarVim. apt says the next:
➜ ~ LV_BRANCH='release-1.2/neovim-0.8' bash <(curl -s https://raw....
2
votes
0
answers
376
views
How to run a Windows executable (exe) from WSL with root privileges?
The title might not be totally accurate, as my goal is to launch an .exe from a WSL2 shell which itself starts a Linux process inside WSL, and I want said Linux process to be ran as root
Goal: Use a ...
2
votes
0
answers
2k
views
Neovim keybinding for LSP "code action" with options
I use neovim and neovim-lsp-config with clangd.
The default keybind for code actions is <space>ca, after pressing which a menu pops up. Usually there is just one option, so having to choose it ...
5
votes
1
answer
8k
views
Coc nvim suggestion selection
I have installed the plugin and also I can see the suggestions. But I am unable to select it I have tried enter, tab, space but still I can’t select it. I have to complete it myself and it is really ...
3
votes
3
answers
11k
views
NeoVim coc.nvim enter key doesn't work to autocomplete
Recently I rewrote my NeoVim config file from vim script to lua and everything is working fine, but I have one issue. When I'm using coc.nvim for autocompletion and I select something, hit enter, ...
1
vote
1
answer
697
views
How to have neovim open a new pane in tmux without switching to it?
This command allows for a new pane to open:
:silent !tmux split-window -h<CR>
But the problem is that my cursor switches to the new pane and I am forced to switch back. How do I turn off the ...
5
votes
2
answers
12k
views
How can I always yank text to clipboard?
I'm currently switching to NeoVim using Mac, and unfortunately the yank key doesn't always work as I expect.
I currently use :%w !pbcopy to copy entire documents.
Is there any problem if I remap the ...
0
votes
1
answer
95
views
How do I fix "E302: Could not rename swap file" when using neovim as my MANPAGER with a non-default swap directory?
I'd like to use neovim to view man pages. To accomplish this, I have the following set in my .bashrc file:
export MANPAGER='nvim +Man!'
On my MacOS system this gives me no problems. But on my Linux ...
2
votes
0
answers
167
views
Avoid indenting the next line of a list in a markdown file
NVIM version v0.6.1
Suppose I am writing a list in markdown and let's say that the cursor is on the item3. Now, doing o in normal mode or Enter in insert mode automatically indents the next line.
+ ...
0
votes
0
answers
3k
views
How to configure jdtls for nvim?
I'm trying to configure jdtls on a Lua based nvim environment following the video of the following series.
I could install the jdtls LSP server and it seems to work fine. When opening a Java file, it ...
1
vote
1
answer
177
views
Neovim - gf equivalent but for an adjacent, existing split
My typical workflow involves having a large "main" split, with a smaller split below for a terminal. When I get a stack trace, I'd like to be able to use gf to go to that location in the ...
1
vote
0
answers
673
views
Is there any way to display CPU, memory information in vim's status bar?
Is there any way to display CPU, memory information in vim's status bar?
I use vim mostly on my own computer, so I don't want to use tmux.
My vim is neovim and the version is v0.6.1.
My OS is Manjaro ...
1
vote
2
answers
4k
views
How can I configure shortcut keys in all modes of vim?
I want to configure a shortcut key that can be used in both edit mode and normal mode, usually two commands are required:
:nnoremap <C-s> :w<cr>
:inoremap <C-s> <esc>:w<cr&...
0
votes
2
answers
680
views
How does vim set indentation for json files?
Other files, like .c, .cpp, .java, etc., I like to indent 4 spaces, but with only .json files, I like to indent 2 spaces.
How can I configure vim for this purpose?
I know it's possible to do :!%jq . ...
1
vote
1
answer
354
views
Command Prompt Black Screen NVIM
I'm facing a really annoying issue with CMD these days.
When attempting to launch neovim on Windows, the display is full black and I don't see any output.
Issue is the same when I SSH into a Linux ...
0
votes
0
answers
3k
views
How come root directory is not detected by "lspconfig" when loading "emmet_ls" client server?
After a recent update, "lspconfig" could no longer detect the client server "emmet_ls." I follow the installation process exactly as followed:
install client server with npm
npm ...
1
vote
3
answers
6k
views
undefined global 'vim' in lua-language-server - coc.nvim
This snippet gives a warning:
local api = vim.api #Undefined global 'vim'
my CocConfig:
` "languageserver": {
"lua": {
"command": "/home/manas/.config/...