ayamir / nvimdots

A well configured and structured Neovim.
BSD 3-Clause "New" or "Revised" License
2.82k stars 450 forks source link

chore: cleanup and minor syntax improvements #1217

Closed Jint-lzxy closed 2 months ago

Jint-lzxy commented 2 months ago

This commit mainly tackled several minor touch-ups and syntax improvements:

ayamir commented 2 months ago

In fact, I'm trying to use vim.region() in https://github.com/neovim/neovim/pull/13896#issuecomment-1621702052 to get selected text but failed. And I also see a relevant PR about it: https://github.com/neovim/neovim/pull/27578 and seem this api will be changed. IMO current impl is enough for 0.9.

Jint-lzxy commented 2 months ago

https://github.com/ayamir/nvimdots/pull/1217/commits/65d580ee62a573ad7ff25bfd1d1c3ab905366e7b further simplified the venv detection logic in dap/clients/python.lua.

Jint-lzxy commented 2 months ago

In fact, I'm trying to use vim.region() in ... to get selected text but failed. And I also see a relevant PR about it: ... and seem this api will be changed. IMO current impl is enough for 0.9.

Agreed. The new vim.getregion() is indeed more "reliable" due to its use of internal calls. Will update the to-do comment accordingly.

UPDATE: See https://github.com/ayamir/nvimdots/pull/1217/commits/354ed808636810f03a4a716b6f4bf465b3aa8fc7.