Neovim

2871 readers
1 users here now

founded 3 years ago
MODERATORS
51
52
 
 

Hi, This will be my first significant open source contribution. A markdown lsp that works as PKMS. It features an interactive graph like one in obsidian.

Currently in beta stage.

Would love your feedback.

And if you like the project consider starring it. I need at least 100 to be able to add it into mason registry for easy installation.

53
54
55
56
 
 

@neovim@programming.dev @neovim@sopuli.xyz Does anyone use #kotlin in #neovim using kotlin_ls? Each time I accept an autocompletion, it instead deletes the whole token.

57
 
 

Hi, I want to try Neovim and am currently setting it up. I want an easier way to type or <C-[>, so I added these keymaps:

vim.keymap.set("", "<C-Space>", "<C-[>")
vim.keymap.set("!", "<C-Space>", "<C-[>")

But this does weird stuff: In insert, visual and normal mode it seems to work and pressing CTRL+Space brings me back to normal mode or does nothing. But when entering a colon-command, pressing CTRL+Space acts as if I had pressed Enter. When typing "r" (single character replace) and then CTRL+Space, it replaces the character by a space, as without the mapping.

The same applies when mapping other keys than instead (the terminal seems to send correctly), or when mapping to instead of <C-[>.

What's going on here and how can I get the mapping to work? Thanks for any help!

58
59
1
My minimal neovim cfg (erock-git-dotfiles.pgs.sh)
submitted 9 months ago by erock@lemmy.ml to c/neovim@programming.dev
 
 

I figured I would join this community with a post sharing my neovim cfg. It’s about as minimal as I can make it, leveraging v0.12 to its fullest.

I’d be curious what others think!

60
 
 

Hi,

As one of my machines is a bit more security sensitive I've been looking into securing neovim a bit more and not having Lua code "free running" on my machine. This is mostly an experiment

I've been happy with the (somewhat) sense of security firejail and neovim profile with no network option gives but then this all goes away once I need to run neovim with network access to update packages et al.

So my question is: is it possible to package all that I need to run neovim (Lua code, mason installed binaries, etc) into an app image or some other format to then run under firejail? Which folders would I need besides the usual ones (.config/neovim)

As for package updates I was thinking about doing it in my personal machine where I would then package everything and install it on the sensitive machine

61
62
 
 

Hello guys, my question is basically in the title. I would really like to be able to have the parameter names included when I cursor over a function and open the 'hover' window to show basic info about it. Currently it only shows me the expected types, which while still useful I feel is only a piece of the puzzle when working either with a new library, or a codebase you're not familiar with.

As an example I'm learning ncurses these past couple days, and its significantly flow-breaking to have to switch focus away from the editor to either search on the web what a particular function takes as parameters, or open a separate terminal to read the man page for it. I'm still not familiar with the library so I frequently need to look up what a parameter represents in the context of the code, in addition to what type I should give it. Is there any way to do this while still using clangd as my lsp server?

Ive also included a screenshot of one such hover window for the ncurses function mvprintw.

63
 
 

I simply want to emulate the effect of -p by default i.e. open all files in tabs when multiple files are supplied. I wrote the following autocommand to make it work.

-- Open files in tabs by default
vim.api.nvim_create_autocmd("VimEnter", {
    callback = function()
        if not vim.opt.diff:get() and #vim.fn.argv() > 1 then
            vim.cmd("tab sball")
            vim.cmd("tabfirst")
        end
    end,
})

But it seems to bork the colorscheme for all but the first tab. It's weird since Running the same commands manually after neovim is loaded works perfectly. I may have something to do with the order in which things are run. Is it possible to run this command as late as possible?

I'm open to alternative approaches that gets the job done.

64
 
 

While LLMs deliver at times questionable quality of code, they can be none the less helpful to give feedback, explain syntax or high level concepts. I was wondering how people are integrating them in neovim. How are you using LLMs? Is it worth thinking about a setup?

65
 
 

Hello fellows!

I never can't stop tweaking my neovim configuration because there's too many people out there that offer incredible plugins!

I eventually took time to dive into snacks.nvim and I've implemented quite some of these features in my config.
Does anybody knows a way to use the undo picker to show the difference between the current node and the node under the cursor instead of comparing the latter with its previous version?

Thanks!

66
1
submitted 1 year ago* (last edited 1 year ago) by wwwgem@lemmy.ml to c/neovim@programming.dev
 
 

Edit: while this post mentions obsidian, it's about the neovim plugin and not the software even though they both share the same name.

Hello there,

I've been trying hard to find a way to implement obsidian in a way that fits my workflow and I may be close to success.
A missing feature for me is the ability to search for notes that include a list of given tags. I know how to search for several tags but the list of results is the notes that include at least one of them while I'd like to see only the notes that include all of them.

Please tell me that's possible, I'm just stupid and missed that, so I can eventually use this terrific plugin everyday.

Thanks!

67
 
 

I use Obsidian for Zettelkasten note-taking. Anybody have a system in (Neo)Vim that they use?

68
 
 

nvim-dap 0.10.0 released

https://github.com/mfussenegger/nvim-dap/releases/tag/0.10.0

This is a smaller one. Mainly to drop support for nvim-0.9.5 on master.

I was hoping I'd get to wrap up the new breakpoint API and data and method breakpoint support, but that will have to wait for 0.11.0 or later.

@neovim
#neovim

69
70
 
 

Hi! I built this small plugin that adds JSX/TSX text-objects and motions using Treesitter: jsx-element.nvim. I was surprised that it (to my knowledge) doesn't exist yet.

From the README:

Use ]t/[t to go to the next/previous JSX/TSX element.

Use it/at to use JSX/TSX elements as text-objects. For example dit for "delete inside tag". This works with self-closing elements:

<Checkbox value="checkedA" />
          ╰───── it ─────╯
╰─────────── at ────────────╯

It also works with paired elements:

<Button variant="text">This is a button</Button>
                       ╰───── it ─────╯
╰───────────────────── at ─────────────────────╯
71
1
submitted 1 year ago* (last edited 1 year ago) by mathias@social.fussenegger.pro to c/neovim@programming.dev
 
 

No-Config Python debugging using neovim

https://zignar.net/2025/03/02/no-config-python-debugging-using-neovim/

A follow up post of my earlier toot about no-config debugging that explains a bit more on how it works. (https://social.fussenegger.pro/@mathias/113970677458792689)

@neovim

#neovim

72
 
 

(Linked video showcases issue quite clearly)

I am using AstroNvim, but I believe that doesn't matter too much in this instance

I am very much new to html and js and the stuffs - but this tag indenting is catching me very offguard.
When I type a new tag it gets indented all nicely, and when opening a new line with o or O key, it nicely puts an indent if I am already in another tag. But when I then save with :w or ZZ, it reformats the indenting again... I think this might be two formatting agents fighting one another with different goals to format the xml tag indenting?

I installed node with npm, as it kinda seems that that is a requirement for working with html stuffs smoothly... and I installed some Lsp and ... stuffs with TsInstall and LspInstall and such... but I would expect those to not change formatting like this.

Has someone here experienced a similar issue? Is nvim in general maybe not the best for webdev? My friend uses brackets, which seems FOSS, but windows only >;(
Until recently, I mostly used nvim only for editing basic json and GDScript files, sometimes some cpp code even, and that worked great so far.

73
1
Lemmy neovim (lemmy.sdf.org)
submitted 1 year ago* (last edited 1 year ago) by you_are_it@lemmy.sdf.org to c/neovim@programming.dev
 
 

So how does this compare to reddit neovim?

Do you recommend some active opensource programming lemmys?

(edit. I'm new to lemmying)

74
 
 

I've been using Neovim for about eight years, but I knever knew about :help o_CTRL-V until today. It lets you perform a command over a column.

I had the code below and wanted to remove all trailing colons:

foo:
bar:
baz:
faz:

What I meant to do was to do was (with the cursor on the first line) $<C-v>3jd to visually select all colons and then delete them. But I accidentally did $d<C-v>3j, which, to my surprise, did the same thing.

I did know about :help o_V, which lets you turn a characterwise operation like di{ into a line-wise one by doing dVi{. But it never occurred to me that I could do the same thing with <C-v>.

75
 
 

Want to switch between projects fast or too lazy to cd into the project directory? Now you directly do that from neovim.

Details on installation in README.

view more: ‹ prev next ›