Compare commits

..

84 Commits

Author SHA1 Message Date
f29543f2c9 chore(main): release 10.2.0 ()
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-10-14 18:30:55 +02:00
95ff5aaa62 feat(extras): added TabNine ()
* feat: add Tabnine

Add TabNine plugin for hrsh7th/nvim-cmp

* fix: limit to top 3 sources for TabNine

* feat: show Tabnine icon on suggestion list

* fix: migrate to LazyVim v10

* refactor: tabnine

* refactor

---------

Co-authored-by: Folke Lemaitre <folke.lemaitre@gmail.com>
2023-10-14 18:25:06 +02:00
1a4342abae refactor: move cmp status lualine component to util 2023-10-14 18:02:47 +02:00
8f42733ce5 feat(python): add key binding for organize imports () 2023-10-14 17:49:23 +02:00
b3d46bc014 feat(lang): add markdown support ()
* feat(lang): add markdown support

* feat: use peek.nvim instead of markdown-preview. Disable and show warning when deno is not installed

* feat: add markdown-preview back

---------

Co-authored-by: Folke Lemaitre <folke.lemaitre@gmail.com>
2023-10-14 17:42:02 +02:00
121df70604 Revert "fix: dont lazy-load on ft. Load on cmd or keys only"
This reverts commit 3a93757bb1ee28c3e1b59c6c47ea5c4e74d8f1b2.
2023-10-14 17:35:13 +02:00
3a93757bb1 fix: dont lazy-load on ft. Load on cmd or keys only 2023-10-14 17:32:06 +02:00
6b9ee963e2 fix(news): dont show news when it has never been viewed (new install) 2023-10-14 16:56:48 +02:00
5b89bc8cbf fix(lsp): trigger FileType commands after installing LSP servers 2023-10-14 16:56:18 +02:00
5e1a86d3b2 feat(toggle): add keymap to toggle treesitter context ()
* feat: add keymap to toggle treesitter context

* fix: get correct enabled state

---------

Co-authored-by: Folke Lemaitre <folke.lemaitre@gmail.com>
2023-10-14 14:40:25 +02:00
f724eae2e3 chore(build): auto-generate vimdoc 2023-10-14 11:22:06 +00:00
ff9bf005b6 fix(dashboard-nvim): repository has moved to nvimdev/dashboard-nvim ()
* fix(dashboard-nvim) repository has moved to nvimdev/dashboard-nvim

* fix(dashboard): automatically rename dashboard.nvim

---------

Co-authored-by: Folke Lemaitre <folke.lemaitre@gmail.com>
2023-10-14 13:21:30 +02:00
7fe68d9f05 fix(spectre): add title to Spectre panel in edgy () 2023-10-13 19:17:50 +02:00
b6e68fa2bf feat(conform): show error when user overwrites conform config function 2023-10-13 18:20:41 +02:00
3eb91c64b5 feat(conform): make it easier to add extra_args 2023-10-13 18:03:40 +02:00
873ff89284 fix(keymaps): no diagnostic keymaps w/o lsp attached () 2023-10-13 16:53:55 +02:00
385c99dbb7 feat(go): add gofumpt formatter with conform/none-ls ()
* feat(go): only install required packages

* fix: add gofumpt formatter using conform/none-ls

* fix: add mason.nvim as dependency of none-ls
2023-10-13 12:43:51 +02:00
c7244d9d47 style(dot): make enabled a function for doc gen 2023-10-13 12:31:32 +02:00
6fd66f486e feat(conform): use conform.nvim opts.format options for formatting with conform 2023-10-13 12:21:38 +02:00
3f1bf70b14 refactor(util.lsp): easier lsp client filters 2023-10-13 12:20:55 +02:00
4584410e76 feat(format): use conform as lsp formatter since it has better format diffs 2023-10-13 09:45:35 +02:00
ea4174d460 chore(main): release 10.1.1 ()
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-10-13 07:39:24 +02:00
1b1d9a16ee docs: typos fixed in CHANGELOG.md () 2023-10-13 07:37:07 +02:00
66f0d55beb chore(build): auto-generate vimdoc 2023-10-13 05:36:45 +00:00
01dbd07073 fix(json): always write version to prevent spurious migrations. Fixes 2023-10-13 07:36:02 +02:00
bd1928ba59 fix(aerial): use new sep_icon option for aerial lualine component 2023-10-13 07:36:02 +02:00
1e79248786 chore(main): release 10.1.0 ()
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-10-12 21:56:56 +02:00
b31d71da9d feat(neot-ree): add keymaps to toggle git & buffer () 2023-10-12 21:52:19 +02:00
1bcf6b9a28 feat(extras): LazyExtras can now manage user extras lua/plugins/extras. Fixes 2023-10-12 21:47:31 +02:00
c9892652d2 feat(config): lazyvim.json is now versioned and migrates to a newer version when needed 2023-10-12 21:45:32 +02:00
8e71968c2b fix(nvim-lint): make sure to set custom linters. Fixes 2023-10-12 20:43:11 +02:00
cdae38ddd4 fix(nvim-lint): check on linter name instead of linter. Fixes 2023-10-12 20:28:58 +02:00
666a69e6e0 chore(main): release 10.0.1 ()
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-10-12 18:07:04 +02:00
7c7b4be8db fix(toggle): dont show incorrect deprecation warning for toggle. Fixes 2023-10-12 17:59:48 +02:00
2a0b7a88ba fix(config): make lazyvim.json idempotent, pretty-printed and remove full paths 2023-10-12 17:48:52 +02:00
7d9a395565 style(format): Fix typo () 2023-10-12 15:10:26 +02:00
763c0fd9f2 chore(main): release 10.0.0 ()
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-10-12 14:49:38 +02:00
73acab1675 feat: added NEWS.md and option to automatically show when changed (enabled by default) 2023-10-12 14:38:25 +02:00
442077fca3 chore(build): auto-generate vimdoc 2023-10-12 09:48:46 +00:00
ce74e28464 feat(starter): added Lazy Extras to mini.starter 2023-10-12 11:48:02 +02:00
b4ba5d881d feat(extras): added extra for symbols-outline.nvim 2023-10-12 11:48:02 +02:00
f64039f546 feat(config): better kind filter default for lua to deal with luals weirdness 2023-10-12 11:48:02 +02:00
a4e393154f fix(extras): make sure we use priorities to import extras in correct order 2023-10-12 11:48:02 +02:00
3256abda65 fix(plugin): show warning of removed core plugin when trying to load them without having the extra 2023-10-12 11:48:02 +02:00
db5d28b039 fix(plugin): add nvim-treesitter-context rename warning 2023-10-12 11:48:02 +02:00
72f3cc684b fix(dap): copy config before overriding args 2023-10-12 11:48:02 +02:00
ba4b8dfecb refactor(nlua): cleanup 2023-10-12 11:48:02 +02:00
14f3f036e9 feat(inject): util method to get upvalue 2023-10-12 11:48:02 +02:00
85215f396b fix(nlua): make nlua dap work with regular continue. Fixes 2023-10-12 11:48:02 +02:00
c7720275c3 fix(aerial): keymap 2023-10-12 11:48:02 +02:00
1c34af7f01 feat(mini.starter): adding mini.starter to lualine disabled files () 2023-10-12 11:48:02 +02:00
eedb4a3405 feat(ui): show optional plugins in a different color 2023-10-12 11:48:02 +02:00
b43c57d943 feat: added aerial extra with integrations for edgy, telescope and lualine 2023-10-12 11:48:02 +02:00
7b2c317407 feat(treesitter): add nvim-treesitter-context by default 2023-10-12 11:48:02 +02:00
13dbe4ad55 perf(lualine): get rid of lualine's weird lualine_require 2023-10-12 11:48:02 +02:00
eb7a7d7a8e feat(config): make kind filter configurable for telescope/aerial/... 2023-10-12 11:48:02 +02:00
cb7f5aca7a feat(treesitter): install nvim-ts-autotag by default 2023-10-12 11:48:02 +02:00
d8250910bd style(config): mini.align icons 2023-10-12 11:48:02 +02:00
e239235cd3 feat(util): inject module 2023-10-12 11:48:02 +02:00
8d7361c460 feat(root): cached pretty path function for statuslines 2023-10-12 11:48:02 +02:00
305e82f2ca feat(navic): moved navic to extras 2023-10-12 11:48:02 +02:00
592f3b03bb fix(root): only use workspace folders that contain the buffer 2023-10-12 11:48:02 +02:00
5bb74205a0 feat(dashboard): added LazyExtras shortcut to dashboard/alpha 2023-10-12 11:48:02 +02:00
c4e55e4d67 feat(ui): added :LazyExtras to manage enabled extras in LazyVim 2023-10-12 11:48:02 +02:00
11d66e7134 feat(config): load/save some data in lazyvim.json 2023-10-12 11:48:02 +02:00
7fb79486ed fix(notify): set default zindex=100 2023-10-12 11:48:02 +02:00
54fa9ce584 ci: let release-please manage the version in the config file 2023-10-12 11:48:02 +02:00
8fbde2c366 fix(neo-tree): during init check global argslist instead of window-local 2023-10-12 11:48:02 +02:00
4ea1c6865e feat(config): use lazy's new custom events (Event.mappings) for a better LazyFile 2023-10-12 11:48:02 +02:00
83734675b0 fix(lualine): when opening nvim with a file, show an empty statusline till lualine loads 2023-10-12 11:48:02 +02:00
a4abbdc89b fix(format): always show formatter status even when no sources available 2023-10-12 11:48:02 +02:00
c33e7489ec feat(root): allow custom functions as part of vim.g.root_spec 2023-10-12 11:48:02 +02:00
f59cdff4d9 fix(plugin): enable lazy_file 2023-10-12 11:48:02 +02:00
a2d604928b feat(root): customizable root detection and :LazyRoot command 2023-10-12 11:48:02 +02:00
e6d294df6f fix(ui): dont show left signs on virtual line numbers (wrap). Fixes 2023-10-12 11:48:02 +02:00
4cbe42cd24 feat(starter)!: dashboard.nvim is now the default starter. To keep using alpha.nvim, enable the extra. 2023-10-12 11:48:02 +02:00
14c091b1fc feat!: make conform.nvim and nvim-lint the default formatters/linters 2023-10-12 11:48:02 +02:00
70f91956e7 perf(plugin): move all lazy.nvim related code to lazyvim.util.plugin 2023-10-12 11:48:02 +02:00
f1a8f24a36 feat(format): new LazyVim formatter with integrations for lsp/none-ls/conform/eslint/... 2023-10-12 11:48:02 +02:00
c8c929c9fd perf(util): split lazyvim.util in smaller separate modules 2023-10-12 11:48:02 +02:00
5f5acb5b88 Revert "fix(config): disable LazyFile till v10.0"
This reverts commit ee7a401388f2933729afcd7090fb8e69631b912f.
2023-10-12 11:48:02 +02:00
61f1c308bf chore(main): release 9.9.1 ()
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2023-10-11 15:00:18 +02:00
ee7a401388 fix(config): disable LazyFile till v10.0 2023-10-11 14:46:08 +02:00
8e88aa51f4 chore(build): auto-generate vimdoc 2023-10-11 12:42:26 +00:00
60 changed files with 2658 additions and 1012 deletions

@ -59,6 +59,8 @@ jobs:
with:
release-type: simple
package-name: LazyVim
extra-files: |
lua/lazyvim/config/init.lua
- uses: actions/checkout@v3
- name: tag stable versions
if: ${{ steps.release.outputs.release_created }}

@ -1,5 +1,126 @@
# Changelog
## [10.2.0](https://github.com/LazyVim/LazyVim/compare/v10.1.1...v10.2.0) (2023-10-14)
### Features
* **conform:** make it easier to add `extra_args` ([3eb91c6](https://github.com/LazyVim/LazyVim/commit/3eb91c64b5960ccd84bd8e6a3318a1ee79cb85c5))
* **conform:** show error when user overwrites conform config function ([b6e68fa](https://github.com/LazyVim/LazyVim/commit/b6e68fa2bf829753be86ba8cc56baafd47b7da67))
* **conform:** use conform.nvim `opts.format` options for formatting with conform ([6fd66f4](https://github.com/LazyVim/LazyVim/commit/6fd66f486e210e35b4c375691fbfd61a611b6027))
* **extras:** added TabNine ([#1651](https://github.com/LazyVim/LazyVim/issues/1651)) ([95ff5aa](https://github.com/LazyVim/LazyVim/commit/95ff5aaa6245244d45609916b0a623c5e8c79d16))
* **format:** use conform as lsp formatter since it has better format diffs ([4584410](https://github.com/LazyVim/LazyVim/commit/4584410e76bf8a6ba426270bef8eca5a100d4cce))
* **go:** add gofumpt formatter with conform/none-ls ([#1683](https://github.com/LazyVim/LazyVim/issues/1683)) ([385c99d](https://github.com/LazyVim/LazyVim/commit/385c99dbb7ccdcf53276086892cceee65b85fa21))
* **lang:** add markdown support ([#1718](https://github.com/LazyVim/LazyVim/issues/1718)) ([b3d46bc](https://github.com/LazyVim/LazyVim/commit/b3d46bc0141c23bfd4302718ff42dfa172c6952b))
* **python:** add key binding for organize imports ([#1670](https://github.com/LazyVim/LazyVim/issues/1670)) ([8f42733](https://github.com/LazyVim/LazyVim/commit/8f42733ce526b6c866b26824d78a1822730c2852))
* **toggle:** add keymap to toggle treesitter context ([#1711](https://github.com/LazyVim/LazyVim/issues/1711)) ([5e1a86d](https://github.com/LazyVim/LazyVim/commit/5e1a86d3b257db37c8b443deea6ca1fefcb0b1aa))
### Bug Fixes
* **dashboard-nvim:** repository has moved to nvimdev/dashboard-nvim ([#1715](https://github.com/LazyVim/LazyVim/issues/1715)) ([ff9bf00](https://github.com/LazyVim/LazyVim/commit/ff9bf005b6957bb46a5541188925f32a1d86365d))
* dont lazy-load on ft. Load on cmd or keys only ([3a93757](https://github.com/LazyVim/LazyVim/commit/3a93757bb1ee28c3e1b59c6c47ea5c4e74d8f1b2))
* **keymaps:** no diagnostic keymaps w/o lsp attached ([#1698](https://github.com/LazyVim/LazyVim/issues/1698)) ([873ff89](https://github.com/LazyVim/LazyVim/commit/873ff892843898033be0b59cee8130c6b1b29d85))
* **lsp:** trigger FileType commands after installing LSP servers ([5b89bc8](https://github.com/LazyVim/LazyVim/commit/5b89bc8cbf990edec201d07c146a3fe28db3302f))
* **news:** dont show news when it has never been viewed (new install) ([6b9ee96](https://github.com/LazyVim/LazyVim/commit/6b9ee963e2684e7b37120b86bab5049918e14899))
* **spectre:** add title to Spectre panel in edgy ([#1703](https://github.com/LazyVim/LazyVim/issues/1703)) ([7fe68d9](https://github.com/LazyVim/LazyVim/commit/7fe68d9f055fd34d95f19a8711e281ab40629482))
## [10.1.1](https://github.com/LazyVim/LazyVim/compare/v10.1.0...v10.1.1) (2023-10-13)
### Bug Fixes
* **aerial:** use new sep_icon option for aerial lualine component ([bd1928b](https://github.com/LazyVim/LazyVim/commit/bd1928ba597d777ca79f9f2f4b14217de4c291bc))
* **json:** always write version to prevent spurious migrations. Fixes [#1692](https://github.com/LazyVim/LazyVim/issues/1692) ([01dbd07](https://github.com/LazyVim/LazyVim/commit/01dbd070738a9448ffbdc63602ed9eb5421158da))
## [10.1.0](https://github.com/LazyVim/LazyVim/compare/v10.0.1...v10.1.0) (2023-10-12)
### Features
* **config:** `lazyvim.json` is now versioned and migrates to a newer version when needed ([c989265](https://github.com/LazyVim/LazyVim/commit/c9892652d271663f52edd7b0d88d2565d8f65a52))
* **extras:** LazyExtras can now manage user extras `lua/plugins/extras`. Fixes [#1681](https://github.com/LazyVim/LazyVim/issues/1681) ([1bcf6b9](https://github.com/LazyVim/LazyVim/commit/1bcf6b9a282bc839d4fde92a94b800185ad58118))
* **neot-ree:** add keymaps to toggle git & buffer ([#1339](https://github.com/LazyVim/LazyVim/issues/1339)) ([b31d71d](https://github.com/LazyVim/LazyVim/commit/b31d71da9d6ca6c290a8ee7e7cc7ad5ccb3cc0bd))
### Bug Fixes
* **nvim-lint:** check on linter name instead of linter. Fixes [#1685](https://github.com/LazyVim/LazyVim/issues/1685) ([cdae38d](https://github.com/LazyVim/LazyVim/commit/cdae38ddd44edbf5e124129fc94e9d1038592760))
* **nvim-lint:** make sure to set custom linters. Fixes [#1687](https://github.com/LazyVim/LazyVim/issues/1687) ([8e71968](https://github.com/LazyVim/LazyVim/commit/8e71968c2bd9e59e535cdac0a99e667f8f120322))
## [10.0.1](https://github.com/LazyVim/LazyVim/compare/v10.0.0...v10.0.1) (2023-10-12)
### Bug Fixes
* **config:** make lazyvim.json idempotent, pretty-printed and remove full paths ([2a0b7a8](https://github.com/LazyVim/LazyVim/commit/2a0b7a88ba4b4562361dd5abb4a071547d004e59))
* **toggle:** dont show incorrect deprecation warning for toggle. Fixes [#1679](https://github.com/LazyVim/LazyVim/issues/1679) ([7c7b4be](https://github.com/LazyVim/LazyVim/commit/7c7b4be8dbec5c5e888d02ebdaae944fecf99407))
## [10.0.0](https://github.com/LazyVim/LazyVim/compare/v9.9.1...v10.0.0) (2023-10-12)
### ⚠ BREAKING CHANGES
* **starter:** `dashboard.nvim` is now the default starter. To keep using `alpha.nvim`, enable the extra.
* make `conform.nvim` and `nvim-lint` the default formatters/linters
### Features
* added aerial extra with integrations for edgy, telescope and lualine ([b43c57d](https://github.com/LazyVim/LazyVim/commit/b43c57d943b2a13460d45f01a288e98cb54f2c1f))
* added NEWS.md and option to automatically show when changed (enabled by default) ([73acab1](https://github.com/LazyVim/LazyVim/commit/73acab16758d37982bd6b2d9b2be37c4ee83cde3))
* **config:** better kind filter default for lua to deal with luals weirdness ([f64039f](https://github.com/LazyVim/LazyVim/commit/f64039f54620fe3fc9e8f464e35b184c6834ed6e))
* **config:** load/save some data in lazyvim.json ([11d66e7](https://github.com/LazyVim/LazyVim/commit/11d66e713467410add9ad5a7a68a3bca0aa24082))
* **config:** make kind filter configurable for telescope/aerial/... ([eb7a7d7](https://github.com/LazyVim/LazyVim/commit/eb7a7d7a8e586d30ed6839f4a621e0f019d32410))
* **config:** use lazy's new custom events (`Event.mappings`) for a better `LazyFile` ([4ea1c68](https://github.com/LazyVim/LazyVim/commit/4ea1c6865e6d877207de8626e11a5a863950ae55))
* **dashboard:** added LazyExtras shortcut to dashboard/alpha ([5bb7420](https://github.com/LazyVim/LazyVim/commit/5bb74205a06a89f048902ba142473dd679b228b8))
* **extras:** added extra for `symbols-outline.nvim` ([b4ba5d8](https://github.com/LazyVim/LazyVim/commit/b4ba5d881dcb801d3c502665f9767d2f75ca1110))
* **format:** new LazyVim formatter with integrations for lsp/none-ls/conform/eslint/... ([f1a8f24](https://github.com/LazyVim/LazyVim/commit/f1a8f24a361d0de198f6b1458168652a6835c932))
* **inject:** util method to get upvalue ([14f3f03](https://github.com/LazyVim/LazyVim/commit/14f3f036e9223315f310ba9d35182690638e7bd7))
* make `conform.nvim` and `nvim-lint` the default formatters/linters ([14c091b](https://github.com/LazyVim/LazyVim/commit/14c091b1fc6b0dc0b22ac49ccac69f8a02e3844c))
* **mini.starter:** adding mini.starter to lualine disabled files ([#1667](https://github.com/LazyVim/LazyVim/issues/1667)) ([1c34af7](https://github.com/LazyVim/LazyVim/commit/1c34af7f0138323d9f465437d0bcef621a8dbe94))
* **navic:** moved navic to extras ([305e82f](https://github.com/LazyVim/LazyVim/commit/305e82f2cacd5d0074027ea545a87a41379afc88))
* **root:** allow custom functions as part of `vim.g.root_spec` ([c33e748](https://github.com/LazyVim/LazyVim/commit/c33e7489ecdaef7295a63079410f2f24a1cbc9b6))
* **root:** cached pretty path function for statuslines ([8d7361c](https://github.com/LazyVim/LazyVim/commit/8d7361c4602993a7ea119cb7ce78d421b6787dfb))
* **root:** customizable root detection and `:LazyRoot` command ([a2d6049](https://github.com/LazyVim/LazyVim/commit/a2d604928b5629d14797437a26022065f7385216))
* **starter:** `dashboard.nvim` is now the default starter. To keep using `alpha.nvim`, enable the extra. ([4cbe42c](https://github.com/LazyVim/LazyVim/commit/4cbe42cd247c72dfc70c3fcddfa3fb6b5e6485e0))
* **starter:** added Lazy Extras to `mini.starter` ([ce74e28](https://github.com/LazyVim/LazyVim/commit/ce74e28464daa7d694f9ab4e41fae3174e30c8b3))
* **treesitter:** add nvim-treesitter-context by default ([7b2c317](https://github.com/LazyVim/LazyVim/commit/7b2c31740782fb0754ce715be6ea128083e48c4f))
* **treesitter:** install nvim-ts-autotag by default ([cb7f5ac](https://github.com/LazyVim/LazyVim/commit/cb7f5aca7a04cf2d1d06397e9a80fe078d17976b))
* **ui:** added `:LazyExtras` to manage enabled extras in LazyVim ([c4e55e4](https://github.com/LazyVim/LazyVim/commit/c4e55e4d67a7195b7aa9160cd8ece3ddc2f6cb51))
* **ui:** show optional plugins in a different color ([eedb4a3](https://github.com/LazyVim/LazyVim/commit/eedb4a34050443448d0b752e22803d5b1278b419))
* **util:** inject module ([e239235](https://github.com/LazyVim/LazyVim/commit/e239235cd34ac9c286eac1e620670784566ef673))
### Bug Fixes
* **aerial:** keymap ([c772027](https://github.com/LazyVim/LazyVim/commit/c7720275c3fa8b19c9ad7e05bfb6ed5c510bf2bb))
* **dap:** copy config before overriding args ([72f3cc6](https://github.com/LazyVim/LazyVim/commit/72f3cc684bd1e8f19b2d3c56da3f359032b8c5dc))
* **extras:** make sure we use priorities to import extras in correct order ([a4e3931](https://github.com/LazyVim/LazyVim/commit/a4e393154f61b95da5835b6461e211eb94740268))
* **format:** always show formatter status even when no sources available ([a4abbdc](https://github.com/LazyVim/LazyVim/commit/a4abbdc89bd1d49378ac5873db1279e7e5398927))
* **lualine:** when opening nvim with a file, show an empty statusline till lualine loads ([8373467](https://github.com/LazyVim/LazyVim/commit/83734675b0f93fbd11a350ee0662c09995836b59))
* **neo-tree:** during init check global argslist instead of window-local ([8fbde2c](https://github.com/LazyVim/LazyVim/commit/8fbde2c3668960ed085f9225bb4650aca77cc495))
* **nlua:** make nlua dap work with regular continue. Fixes [#1666](https://github.com/LazyVim/LazyVim/issues/1666) ([85215f3](https://github.com/LazyVim/LazyVim/commit/85215f396b6fd4de24636a202ec1149dafa5f7b5))
* **notify:** set default zindex=100 ([7fb7948](https://github.com/LazyVim/LazyVim/commit/7fb79486ed1b251b98b95a44ef50b3742edd708d))
* **plugin:** add nvim-treesitter-context rename warning ([db5d28b](https://github.com/LazyVim/LazyVim/commit/db5d28b039f656ccb47d3b9f787e8bb482cc6ec1))
* **plugin:** enable lazy_file ([f59cdff](https://github.com/LazyVim/LazyVim/commit/f59cdff4d9f04ff349cefdee0b363d573954ce0d))
* **plugin:** show warning of removed core plugin when trying to load them without having the extra ([3256abd](https://github.com/LazyVim/LazyVim/commit/3256abda65ae03358ecdbef1c7789782440fe39e))
* **root:** only use workspace folders that contain the buffer ([592f3b0](https://github.com/LazyVim/LazyVim/commit/592f3b03bb3cd01df42ee5db4cd6ba43937f067e))
* **ui:** dont show left signs on virtual line numbers (wrap). Fixes [#1654](https://github.com/LazyVim/LazyVim/issues/1654) ([e6d294d](https://github.com/LazyVim/LazyVim/commit/e6d294df6fbd973644d4b7f9691d5f48cc5efdde))
### Performance Improvements
* **lualine:** get rid of lualine's weird lualine_require ([13dbe4a](https://github.com/LazyVim/LazyVim/commit/13dbe4ad55a4e4b9a3dd345521b359411cdc5879))
* **plugin:** move all lazy.nvim related code to `lazyvim.util.plugin` ([70f9195](https://github.com/LazyVim/LazyVim/commit/70f91956e7f03e740b51cbc14c87df6a6f74538f))
* **util:** split lazyvim.util in smaller separate modules ([c8c929c](https://github.com/LazyVim/LazyVim/commit/c8c929c9fdc44cc69cb034c47bd89d2bc4e4a429))
## [9.9.1](https://github.com/LazyVim/LazyVim/compare/v9.9.0...v9.9.1) (2023-10-11)
### Bug Fixes
* **config:** disable LazyFile till v10.0 ([ee7a401](https://github.com/LazyVim/LazyVim/commit/ee7a401388f2933729afcd7090fb8e69631b912f))
## [9.9.0](https://github.com/LazyVim/LazyVim/compare/v9.8.0...v9.9.0) (2023-10-10)
@ -171,7 +292,7 @@
### Bug Fixes
* **dasboard:** disable alpha only once ([d6b56c0](https://github.com/LazyVim/LazyVim/commit/d6b56c075e88ce12e9e16fb2eeeea38fb7853600))
* **dashboard:** disable alpha only once ([d6b56c0](https://github.com/LazyVim/LazyVim/commit/d6b56c075e88ce12e9e16fb2eeeea38fb7853600))
* **options:** set default laststatus=3 and set it to 0 before loading dashboard to prevent flickering ([1eb0192](https://github.com/LazyVim/LazyVim/commit/1eb019274b5564e66ac6c7e119c140bae262e10c))
* **tailwind:** allow overriding filetypes. Fixes [#1590](https://github.com/LazyVim/LazyVim/issues/1590) ([d3e7f77](https://github.com/LazyVim/LazyVim/commit/d3e7f7717e960bb883b35e9a75badfd5b938cace))
@ -212,7 +333,7 @@
### Bug Fixes
* **autocmds:** retore last location for correct buffer ([afc8e7f](https://github.com/LazyVim/LazyVim/commit/afc8e7f8cac06335efd12ec5f71cabb1f38a09b0))
* **autocmds:** restore last location for correct buffer ([afc8e7f](https://github.com/LazyVim/LazyVim/commit/afc8e7f8cac06335efd12ec5f71cabb1f38a09b0))
* **conform:** dont try merging function formatters. Fixes [#1582](https://github.com/LazyVim/LazyVim/issues/1582) ([f475085](https://github.com/LazyVim/LazyVim/commit/f4750859f2c2c9a41b3974ac05962ce9648d6c16))
* **conform:** dont try to merge formatter functions ([9f034ab](https://github.com/LazyVim/LazyVim/commit/9f034ab10650e306e178d5189ee9214a52f2e8e5))
* **nvim-lint:** dont try merging function linters ([79010ae](https://github.com/LazyVim/LazyVim/commit/79010ae671035d8ed0040ce51df4fb59ec3962f8))
@ -935,7 +1056,7 @@
* **hipatterns:** default options ([3082436](https://github.com/LazyVim/LazyVim/commit/30824369c2c58647df170566766ea1dbda2730cc))
* **neotest:** added some additional filetypes to close with q ([1288f0d](https://github.com/LazyVim/LazyVim/commit/1288f0d5a5cc5f5279678cc3c3d99abe20a1e052))
* **neotest:** support neotest adapaters that use `setup()` for custom setup ([2a3bac7](https://github.com/LazyVim/LazyVim/commit/2a3bac769045abac76395fcabb36b17b68bc42fc))
* **neotest:** support neotest adapters that use `setup()` for custom setup ([2a3bac7](https://github.com/LazyVim/LazyVim/commit/2a3bac769045abac76395fcabb36b17b68bc42fc))
## [4.2.0](https://github.com/LazyVim/LazyVim/compare/v4.1.1...v4.2.0) (2023-05-26)
@ -1542,7 +1663,7 @@
### Bug Fixes
* **illuminate:** always set refernce keymaps on the buffer as well to properly overwrite ftplugin mappings. Fixes [#292](https://github.com/LazyVim/LazyVim/issues/292) ([a0cf00c](https://github.com/LazyVim/LazyVim/commit/a0cf00c81b3a4a352cdc26c94112d9a5827881e1))
* **illuminate:** always set reference keymaps on the buffer as well to properly overwrite ftplugin mappings. Fixes [#292](https://github.com/LazyVim/LazyVim/issues/292) ([a0cf00c](https://github.com/LazyVim/LazyVim/commit/a0cf00c81b3a4a352cdc26c94112d9a5827881e1))
* **mini.surround:** don't create empty keymaps. Fixes [#296](https://github.com/LazyVim/LazyVim/issues/296) ([8e84dcf](https://github.com/LazyVim/LazyVim/commit/8e84dcf85c8a73ebcf6ade6b7b77544f468f1dfa))
* **treesitter:** disable indent only for python right now ([de6a28b](https://github.com/LazyVim/LazyVim/commit/de6a28b781e8a06e4f70c913539c97260392131a))
* **treesitter:** disable treesitter indent by default, since it has too many issues. See [#297](https://github.com/LazyVim/LazyVim/issues/297) ([329a2da](https://github.com/LazyVim/LazyVim/commit/329a2daff493abd2bd5c8fedbf0dfa13039d3931))
@ -1686,7 +1807,7 @@
### Bug Fixes
* **mini.ai:** load ai on VeryLazy. Keymaps interfer with which-key. [#155](https://github.com/LazyVim/LazyVim/issues/155) ([3b5f363](https://github.com/LazyVim/LazyVim/commit/3b5f36307438ad05beae6796ca005f6b56d6a360))
* **mini.ai:** load ai on VeryLazy. Keymaps interfere with which-key. [#155](https://github.com/LazyVim/LazyVim/issues/155) ([3b5f363](https://github.com/LazyVim/LazyVim/commit/3b5f36307438ad05beae6796ca005f6b56d6a360))
* **noice:** scroll doc window in normal, insert and select mode ([c5b22c0](https://github.com/LazyVim/LazyVim/commit/c5b22c0832603198f571ff68b6fb9d0c17f73d33))
* **nvim-navic:** use kinds icons for navic. Fixes [#164](https://github.com/LazyVim/LazyVim/issues/164) ([b81ecf9](https://github.com/LazyVim/LazyVim/commit/b81ecf9f7ac78e3f87a4d9b305fa0d3cfd6decf2))
@ -1861,7 +1982,7 @@
* **lsp:** allow overriding options for vim.lsp.buf.format. Fixes [#51](https://github.com/LazyVim/LazyVim/issues/51) ([40d363c](https://github.com/LazyVim/LazyVim/commit/40d363cf3f468a1cc4ea482eaabbd5c7e224f397))
* **lsp:** make diagnostics configurable with `{"neovim/nvim-lspconfig", opts = {diagnostics = {}}}`. Fixes [#55](https://github.com/LazyVim/LazyVim/issues/55) ([1efc925](https://github.com/LazyVim/LazyVim/commit/1efc925d16b57659cbb9af5a1579cb1b9ee9643f))
* **neo-tree:** added `&lt;leader&gt;e` and `<leader>E` to toggle neo-tree ([542920f](https://github.com/LazyVim/LazyVim/commit/542920fb8249d45d1e9ddbf6517a8f8539769eda))
* **neo-tree:** load neo-tree when specifying a direcory on the cmdline ([81d798f](https://github.com/LazyVim/LazyVim/commit/81d798fdaa5bf49737969e0f15af4a90621a0a61))
* **neo-tree:** load neo-tree when specifying a directory on the cmdline ([81d798f](https://github.com/LazyVim/LazyVim/commit/81d798fdaa5bf49737969e0f15af4a90621a0a61))
* **notify:** delay notifs till replaced or at most 500ms to prevent more prompts ([701337f](https://github.com/LazyVim/LazyVim/commit/701337fac8cb1de0f3e31400cef30b053762320f))
* **notify:** lazy-load nvim-notify to show proper notifs before Noice loads ([7406313](https://github.com/LazyVim/LazyVim/commit/74063135d838b0ed9fe1a8d0e777c8cfe83ae28f))
* **util:** use lazy's notify instead of `vim.notify` ([48d1e8d](https://github.com/LazyVim/LazyVim/commit/48d1e8df12795cf559f704223b63e76259998582))

68
NEWS.md Normal file

@ -0,0 +1,68 @@
# What's new?
## 10.x
- User extras under `lua/plugins/extras` can now also be managed
with **LazyExtras**
- `nvim-ts-autotag` is now included by default
- `nvim-treesitter-context` is now included by default
- Added extra for `symbols-outline.nvim`
- Added extra for `aerial.nvim`
- `nvim-navic` has been removed. If you want to keep using `nvim-navic`,
you can enable the **editor.navic** extra
- New `:LazyExtras` command for managing **LazyVim** extras
- Improved **formatting**:
- **LazyVim** can now work with multiple formatters. Types:
- **primary**: only one primary formatter can be active at a time.
_(conform, none-ls, LSP)_
- **secondary**: multiple secondary formatters can be active _(eslint, ...)_
- **LazyVim** automatically selects the primary formatter based on the
current available sources and priorities.
- New `:LazyFormat` command for formatting the current selection or buffer
- New `:LazyFormatInfo` command for displaying the active formatters
for the current buffer
- Auto-formatting can be disabled with:
```lua
vim.g.autoformat = false -- globally
vim.b.autoformat = false -- buffer-local
```
- `none-ls.nvim` is no longer installed by default
- `conform.nvim` is now the default formatter
- `nvim-lint` is now the default linter
- If you want to keep using `none-ls.nvim`,
you can enable the **lsp.none-ls** extra
- `dashboard.nvim` is the new default dashboard plugin
- If you want to keep using `alpha.nvim`, you can enable the **ui.alpha** extra
- Improved **root detection**:
- New `:LazyRoot` command that shows info about the root dir detection
- Configurable with `vim.g.root_spec`
```lua
-- LazyVim root dir detection
-- Each entry can be:
-- * the name of a detector function like `lsp` or `cwd`
-- * a pattern or array of patterns like `.git` or `lua`.
-- * a function with signature `function(buf) -> string|string[]`
vim.g.root_spec = { "lsp", { ".git", "lua" }, "cwd" }
-- To disable root detection set to just "cwd"
vim.g.root_spec = { "cwd" }
```

@ -1,4 +1,4 @@
*LazyVim.txt* For Neovim >= 0.8.0 Last change: 2023 October 10
*LazyVim.txt* For Neovim >= 0.8.0 Last change: 2023 October 14
==============================================================================
Table of Contents *LazyVim-table-of-contents*

File diff suppressed because it is too large Load Diff

@ -95,18 +95,35 @@ end
-- formatting
map({ "n", "v" }, "<leader>cf", function()
require("lazyvim.plugins.lsp.format").format({ force = true })
Util.format({ force = true })
end, { desc = "Format" })
-- diagnostic
local diagnostic_goto = function(next, severity)
local go = next and vim.diagnostic.goto_next or vim.diagnostic.goto_prev
severity = severity and vim.diagnostic.severity[severity] or nil
return function()
go({ severity = severity })
end
end
map("n", "<leader>cd", vim.diagnostic.open_float, { desc = "Line Diagnostics" })
map("n", "]d", diagnostic_goto(true), { desc = "Next Diagnostic" })
map("n", "[d", diagnostic_goto(false), { desc = "Prev Diagnostic" })
map("n", "]e", diagnostic_goto(true, "ERROR"), { desc = "Next Error" })
map("n", "[e", diagnostic_goto(false, "ERROR"), { desc = "Prev Error" })
map("n", "]w", diagnostic_goto(true, "WARN"), { desc = "Next Warning" })
map("n", "[w", diagnostic_goto(false, "WARN"), { desc = "Prev Warning" })
-- stylua: ignore start
-- toggle options
map("n", "<leader>uf", require("lazyvim.plugins.lsp.format").toggle, { desc = "Toggle format on Save" })
map("n", "<leader>uf", function() Util.format.toggle() end, { desc = "Toggle auto format (global)" })
map("n", "<leader>uF", function() Util.format.toggle(true) end, { desc = "Toggle auto format (buffer)" })
map("n", "<leader>us", function() Util.toggle("spell") end, { desc = "Toggle Spelling" })
map("n", "<leader>uw", function() Util.toggle("wrap") end, { desc = "Toggle Word Wrap" })
map("n", "<leader>uL", function() Util.toggle("relativenumber") end, { desc = "Toggle Relative Line Numbers" })
map("n", "<leader>ul", function() Util.toggle_number() end, { desc = "Toggle Line Numbers" })
map("n", "<leader>ud", Util.toggle_diagnostics, { desc = "Toggle Diagnostics" })
map("n", "<leader>ul", function() Util.toggle.number() end, { desc = "Toggle Line Numbers" })
map("n", "<leader>ud", function() Util.toggle.diagnostics() end, { desc = "Toggle Diagnostics" })
local conceallevel = vim.o.conceallevel > 0 and vim.o.conceallevel or 3
map("n", "<leader>uc", function() Util.toggle("conceallevel", false, {0, conceallevel}) end, { desc = "Toggle Conceal" })
if vim.lsp.inlay_hint then
@ -114,8 +131,8 @@ if vim.lsp.inlay_hint then
end
-- lazygit
map("n", "<leader>gg", function() Util.float_term({ "lazygit" }, { cwd = Util.get_root(), esc_esc = false, ctrl_hjkl = false }) end, { desc = "Lazygit (root dir)" })
map("n", "<leader>gG", function() Util.float_term({ "lazygit" }, {esc_esc = false, ctrl_hjkl = false}) end, { desc = "Lazygit (cwd)" })
map("n", "<leader>gg", function() Util.terminal({ "lazygit" }, { cwd = Util.root(), esc_esc = false, ctrl_hjkl = false }) end, { desc = "Lazygit (root dir)" })
map("n", "<leader>gG", function() Util.terminal({ "lazygit" }, {esc_esc = false, ctrl_hjkl = false}) end, { desc = "Lazygit (cwd)" })
-- quit
map("n", "<leader>qq", "<cmd>qa<cr>", { desc = "Quit all" })
@ -124,12 +141,12 @@ map("n", "<leader>qq", "<cmd>qa<cr>", { desc = "Quit all" })
map("n", "<leader>ui", vim.show_pos, { desc = "Inspect Pos" })
-- LazyVim Changelog
map("n", "<leader>L", Util.changelog, {desc = "LazyVim Changelog"})
map("n", "<leader>L", function() Util.news.changelog() end, { desc = "LazyVim Changelog" })
-- floating terminal
local lazyterm = function() Util.float_term(nil, { cwd = Util.get_root() }) end
local lazyterm = function() Util.terminal(nil, { cwd = Util.root() }) end
map("n", "<leader>ft", lazyterm, { desc = "Terminal (root dir)" })
map("n", "<leader>fT", function() Util.float_term() end, { desc = "Terminal (cwd)" })
map("n", "<leader>fT", function() Util.terminal() end, { desc = "Terminal (cwd)" })
map("n", "<c-/>", lazyterm, { desc = "Terminal (root dir)" })
map("n", "<c-_>", lazyterm, { desc = "which_key_ignore" })

@ -2,6 +2,16 @@
vim.g.mapleader = " "
vim.g.maplocalleader = "\\"
-- Enable LazyVim auto format
vim.g.autoformat = true
-- LazyVim root dir detection
-- Each entry can be:
-- * the name of a detector function like `lsp` or `cwd`
-- * a pattern or array of patterns like `.git` or `lua`.
-- * a function with signature `function(buf) -> string|string[]`
vim.g.root_spec = { "lsp", { ".git", "lua" }, "cwd" }
local opt = vim.opt
opt.autowrite = true -- Enable auto write
@ -63,10 +73,10 @@ end
-- Folding
vim.opt.foldlevel = 99
vim.opt.foldtext = "v:lua.require'lazyvim.util.ui'.foldtext()"
vim.opt.foldtext = "v:lua.require'lazyvim.util'.ui.foldtext()"
if vim.fn.has("nvim-0.9.0") == 1 then
vim.opt.statuscolumn = [[%!v:lua.require'lazyvim.util.ui'.statuscolumn()]]
vim.opt.statuscolumn = [[%!v:lua.require'lazyvim.util'.ui.statuscolumn()]]
end
-- HACK: causes freezes on <= 0.9, so only enable on >= 0.10 for now

@ -11,7 +11,7 @@ return {
{
"<leader>fe",
function()
require("neo-tree.command").execute({ toggle = true, dir = require("lazyvim.util").get_root() })
require("neo-tree.command").execute({ toggle = true, dir = Util.root() })
end,
desc = "Explorer NeoTree (root dir)",
},
@ -24,12 +24,26 @@ return {
},
{ "<leader>e", "<leader>fe", desc = "Explorer NeoTree (root dir)", remap = true },
{ "<leader>E", "<leader>fE", desc = "Explorer NeoTree (cwd)", remap = true },
{
"<leader>ge",
function()
require("neo-tree.command").execute({ source = "git_status", toggle = true })
end,
desc = "Git explorer",
},
{
"<leader>be",
function()
require("neo-tree.command").execute({ source = "buffers", toggle = true })
end,
desc = "Buffer explorer",
},
},
deactivate = function()
vim.cmd([[Neotree close]])
end,
init = function()
if vim.fn.argc() == 1 then
if vim.fn.argc(-1) == 1 then
local stat = vim.loop.fs_stat(vim.fn.argv(0))
if stat and stat.type == "directory" then
require("neo-tree")
@ -60,7 +74,7 @@ return {
},
config = function(_, opts)
local function on_move(data)
Util.on_rename(data.source, data.destination)
Util.lsp.on_rename(data.source, data.destination)
end
local events = require("neo-tree.events")
@ -150,42 +164,20 @@ return {
{ "<leader>uC", Util.telescope("colorscheme", { enable_preview = true }), desc = "Colorscheme with preview" },
{
"<leader>ss",
Util.telescope("lsp_document_symbols", {
symbols = {
"Class",
"Function",
"Method",
"Constructor",
"Interface",
"Module",
"Struct",
"Trait",
"Field",
"Property",
"Enum",
"Constant",
},
}),
function()
require("telescope.builtin").lsp_document_symbols({
symbols = require("lazyvim.config").get_kind_filter(),
})
end,
desc = "Goto Symbol",
},
{
"<leader>sS",
Util.telescope("lsp_dynamic_workspace_symbols", {
symbols = {
"Class",
"Function",
"Method",
"Constructor",
"Interface",
"Module",
"Struct",
"Trait",
"Field",
"Property",
"Enum",
"Constant",
},
}),
function()
require("telescope.builtin").lsp_dynamic_workspace_symbols({
symbols = require("lazyvim.config").get_kind_filter(),
})
end,
desc = "Goto Symbol (Workspace)",
},
},
@ -270,7 +262,7 @@ return {
"nvim-telescope/telescope.nvim",
optional = true,
opts = function(_, opts)
if not require("lazyvim.util").has("flash.nvim") then
if not Util.has("flash.nvim") then
return
end
local function flash(prompt_bufnr)

@ -27,43 +27,7 @@ return {
optional = true,
event = "VeryLazy",
opts = function(_, opts)
local started = false
local function status()
if not package.loaded["cmp"] then
return
end
for _, s in ipairs(require("cmp").core.sources) do
if s.name == "codeium" then
if s.source:is_available() then
started = true
else
return started and "error" or nil
end
if s.status == s.SourceStatus.FETCHING then
return "pending"
end
return "ok"
end
end
end
local Util = require("lazyvim.util")
local colors = {
ok = Util.fg("Special"),
error = Util.fg("DiagnosticError"),
pending = Util.fg("DiagnosticWarn"),
}
table.insert(opts.sections.lualine_x, 2, {
function()
return require("lazyvim.config").icons.kinds.Codeium
end,
cond = function()
return status() ~= nil
end,
color = function()
return colors[status()] or colors.ok
end,
})
table.insert(opts.sections.lualine_x, 2, require("lazyvim.util").lualine.cmp_source("codeium"))
end,
},
}

@ -21,10 +21,10 @@ return {
opts = function(_, opts)
local Util = require("lazyvim.util")
local colors = {
[""] = Util.fg("Special"),
["Normal"] = Util.fg("Special"),
["Warning"] = Util.fg("DiagnosticError"),
["InProgress"] = Util.fg("DiagnosticWarn"),
[""] = Util.ui.fg("Special"),
["Normal"] = Util.ui.fg("Special"),
["Warning"] = Util.ui.fg("DiagnosticError"),
["InProgress"] = Util.ui.fg("DiagnosticWarn"),
}
table.insert(opts.sections.lualine_x, 2, {
function()
@ -36,7 +36,7 @@ return {
if not package.loaded["copilot"] then
return
end
local ok, clients = pcall(require("lazyvim.util").get_clients, { name = "copilot", bufnr = 0 })
local ok, clients = pcall(require("lazyvim.util").lsp.get_clients, { name = "copilot", bufnr = 0 })
if not ok then
return false
end
@ -66,7 +66,7 @@ return {
copilot_cmp.setup(opts)
-- attach cmp source whenever copilot attaches
-- fixes lazy-loading issues with the copilot cmp source
require("lazyvim.util").on_attach(function(client)
require("lazyvim.util").lsp.on_attach(function(client)
if client.name == "copilot" then
copilot_cmp._on_insert_enter({})
end

@ -0,0 +1,50 @@
local Util = require("lazyvim.util")
return {
-- Tabnine cmp source
{
"nvim-cmp",
dependencies = {
-- Add TabNine support, make sure you run :CmpTabnineHub after installation.
{
"tzachar/cmp-tabnine",
build = "./install.sh",
dependencies = "hrsh7th/nvim-cmp",
opts = {
max_lines = 1000,
max_num_results = 3,
sort = true,
},
config = function(_, opts)
local tabnine = require("cmp_tabnine.config")
tabnine:setup(opts)
end,
},
},
---@param opts cmp.ConfigSchema
opts = function(_, opts)
table.insert(opts.sources, 1, {
name = "cmp_tabnine",
group_index = 1,
priority = 100,
})
opts.formatting.format = Util.inject.args(opts.formatting.format, function(entry, item)
-- Hide percentage in the menu
if entry.source.name == "cmp_tabnine" then
item.menu = ""
end
end)
end,
},
-- Show TabNine status in lualine
{
"nvim-lualine/lualine.nvim",
optional = true,
event = "VeryLazy",
opts = function(_, opts)
local icon = require("lazyvim.config").icons.kinds.TabNine
table.insert(opts.sections.lualine_x, 2, require("lazyvim.util").lualine.cmp_source("cmp_tabnine", icon))
end,
},
}

@ -1,6 +1,7 @@
---@param config {args?:string[]|fun():string[]?}
local function get_args(config)
local args = type(config.args) == "function" and (config.args() or {}) or config.args or {}
config = vim.deepcopy(config)
---@cast args string[]
config.args = function()
local new_args = vim.fn.input("Run with args: ", table.concat(args, " ")) --[[@as string]]
@ -54,7 +55,6 @@ return {
opts = {
defaults = {
["<leader>d"] = { name = "+debug" },
["<leader>da"] = { name = "+adapters" },
},
},
},

@ -1,24 +1,40 @@
return {
"mfussenegger/nvim-dap",
dependencies = {
{
"jbyuki/one-small-step-for-vimkind",
-- stylua: ignore
keys = {
{ "<leader>daL", function() require("osv").launch({ port = 8086 }) end, desc = "Adapter Lua Server", ft = "lua" },
{ "<leader>dal", function() require("osv").run_this() end, desc = "Adapter Lua", ft = "lua" },
},
config = function()
local dap = require("dap")
dap.adapters.nlua = function(callback, config)
callback({ type = "server", host = config.host or "127.0.0.1", port = config.port or 8086 })
dap.adapters.nlua = function(callback, conf)
local adapter = {
type = "server",
host = conf.host or "127.0.0.1",
port = conf.port or 8086,
}
if conf.start_neovim then
local dap_run = dap.run
dap.run = function(c)
adapter.port = c.port
adapter.host = c.host
end
require("osv").run_this()
dap.run = dap_run
end
callback(adapter)
end
dap.configurations.lua = {
{
type = "nlua",
request = "attach",
name = "Attach to running Neovim instance",
name = "Run this file",
start_neovim = {},
},
{
type = "nlua",
request = "attach",
name = "Attach to running Neovim instance (port = 8086)",
port = 8086,
},
}
end,

@ -0,0 +1,123 @@
local Config = require("lazyvim.config")
local Util = require("lazyvim.util")
return {
desc = "Aerial Symbol Browser",
{
"stevearc/aerial.nvim",
event = "LazyFile",
opts = function()
local icons = vim.deepcopy(Config.icons.kinds)
-- HACK: fix lua's weird choice for `Package` for control
-- structures like if/else/for/etc.
icons.lua = { Package = icons.Control }
---@type table<string, string[]>|false
local filter_kind = false
if Config.kind_filter then
filter_kind = assert(vim.deepcopy(Config.kind_filter))
filter_kind._ = filter_kind.default
filter_kind.default = nil
end
local opts = {
attach_mode = "global",
backends = { "lsp", "treesitter", "markdown", "man" },
show_guides = true,
layout = {
resize_to_content = false,
win_opts = {
winhl = "Normal:NormalFloat,FloatBorder:NormalFloat,SignColumn:SignColumnSB",
signcolumn = "yes",
statuscolumn = " ",
},
},
icons = icons,
filter_kind = filter_kind,
-- stylua: ignore
guides = {
mid_item = "├╴",
last_item = "└╴",
nested_top = "",
whitespace = " ",
},
}
return opts
end,
keys = {
{ "<leader>cs", "<cmd>AerialToggle<cr>", desc = "Aerial (Symbols)" },
},
},
-- Telescope integration
{
"nvim-telescope/telescope.nvim",
optional = true,
opts = function()
Util.on_load("telescope.nvim", function()
require("telescope").load_extension("aerial")
end)
end,
keys = {
{
"<leader>ss",
"<cmd>Telescope aerial<cr>",
desc = "Goto Symbol (Aerial)",
},
},
},
-- edgy integration
{
"folke/edgy.nvim",
optional = true,
opts = function(_, opts)
local edgy_idx = Util.plugin.extra_idx("ui.edgy")
local aerial_idx = Util.plugin.extra_idx("editor.aerial")
if edgy_idx and edgy_idx > aerial_idx then
Util.warn("The `edgy.nvim` extra must be **imported** before the `aerial.nvim` extra to work properly.", {
title = "LazyVim",
})
end
opts.right = opts.right or {}
table.insert(opts.right, {
title = "Aerial",
ft = "aerial",
pinned = true,
open = "AerialOpen",
})
end,
},
-- lualine integration
{
"nvim-lualine/lualine.nvim",
optional = true,
opts = function(_, opts)
table.insert(opts.sections.lualine_c, {
"aerial",
sep = " ", -- separator between symbols
sep_icon = "", -- separator between icon and symbol
-- The number of symbols to render top-down. In order to render only 'N' last
-- symbols, negative numbers may be supplied. For instance, 'depth = -1' can
-- be used in order to render only current symbol.
depth = 5,
-- When 'dense' mode is on, icons are not rendered near their symbols. Only
-- a single icon that represents the kind of current symbol is rendered at
-- the beginning of status line.
dense = false,
-- The separator to be used to separate symbols in dense mode.
dense_sep = ".",
-- Color the symbol icons.
colored = true,
})
end,
},
}

@ -57,7 +57,7 @@ return {
vim.api.nvim_create_autocmd("User", {
pattern = "MiniFilesActionRename",
callback = function(event)
require("lazyvim.util").on_rename(event.data.from, event.data.to)
require("lazyvim.util").lsp.on_rename(event.data.from, event.data.to)
end,
})
end,

@ -0,0 +1,42 @@
return {
-- lsp symbol navigation for lualine. This shows where
-- in the code structure you are - within functions, classes,
-- etc - in the statusline.
{
"SmiteshP/nvim-navic",
lazy = true,
init = function()
vim.g.navic_silence = true
require("lazyvim.util").lsp.on_attach(function(client, buffer)
if client.supports_method("textDocument/documentSymbol") then
require("nvim-navic").attach(client, buffer)
end
end)
end,
opts = function()
return {
separator = " ",
highlight = true,
depth_limit = 5,
icons = require("lazyvim.config").icons.kinds,
lazy_update_context = true,
}
end,
},
-- lualine integration
{
"nvim-lualine/lualine.nvim",
optional = true,
opts = function(_, opts)
table.insert(opts.sections.lualine_c, {
function()
return require("nvim-navic").get_location()
end,
cond = function()
return package.loaded["nvim-navic"] and require("nvim-navic").is_available()
end,
})
end,
},
}

@ -0,0 +1,55 @@
local Util = require("lazyvim.util")
return {
{
"simrat39/symbols-outline.nvim",
keys = { { "<leader>cs", "<cmd>SymbolsOutline<cr>", desc = "Symbols Outline" } },
cmd = "SymbolsOutline",
opts = function()
local Config = require("lazyvim.config")
local defaults = require("symbols-outline.config").defaults
local opts = {
symbols = {},
symbol_blacklist = {},
}
for kind, symbol in pairs(defaults.symbols) do
opts.symbols[kind] = {
icon = Config.icons.kinds[kind] or symbol.icon,
hl = symbol.hl,
}
if not vim.tbl_contains(Config.kind_filter.default, kind) then
table.insert(opts.symbol_blacklist, kind)
end
end
return opts
end,
},
-- edgy integration
{
"folke/edgy.nvim",
optional = true,
opts = function(_, opts)
local edgy_idx = Util.plugin.extra_idx("ui.edgy")
local symbols_idx = Util.plugin.extra_idx("editor.symbols-outline")
if edgy_idx and edgy_idx > symbols_idx then
Util.warn(
"The `edgy.nvim` extra must be **imported** before the `symbols-outline.nvim` extra to work properly.",
{
title = "LazyVim",
}
)
end
opts.right = opts.right or {}
table.insert(opts.right, {
title = "Symbols Outline",
ft = "Outline",
pinned = true,
open = "SymbolsOutline",
})
end,
},
}

@ -10,6 +10,7 @@ return {
optional = true,
opts = function(_, opts)
local nls = require("null-ls")
opts.sources = opts.sources or {}
table.insert(opts.sources, nls.builtins.formatting.black)
end,
},

@ -1,58 +0,0 @@
return {
{
"stevearc/conform.nvim",
dependencies = { "mason.nvim" },
lazy = true,
cmd = "ConformInfo",
keys = {
{
"<leader>cF",
function()
require("conform").format({ formatters = { "injected" } })
end,
mode = { "n", "v" },
desc = "Format Injected Langs",
},
},
init = function()
vim.o.formatexpr = "v:lua.require'conform'.formatexpr()"
-- Install the conform formatter on VeryLazy
require("lazyvim.util").on_very_lazy(function()
require("lazyvim.plugins.lsp.format").custom_format = function(buf)
return require("conform").format({ bufnr = buf })
end
end)
end,
opts = {
formatters_by_ft = {
lua = { "stylua" },
fish = { "fish_indent" },
sh = { "shfmt" },
},
-- LazyVim will merge the options you set here with builtin formatters.
-- You can also define any custom formatters here.
---@type table<string,table>
formatters = {
injected = { options = { ignore_errors = true } },
-- -- Example of using dprint only when a dprint.json file is present
-- dprint = {
-- condition = function(ctx)
-- return vim.fs.find({ "dprint.json" }, { path = ctx.filename, upward = true })[1]
-- end,
-- },
},
},
config = function(_, opts)
opts.formatters = opts.formatters or {}
for name, formatter in pairs(opts.formatters) do
if type(formatter) == "table" then
local ok, defaults = pcall(require, "conform.formatters." .. name)
if ok and type(defaults) == "table" then
opts.formatters[name] = vim.tbl_deep_extend("force", {}, defaults, formatter)
end
end
end
require("conform").setup(opts)
end,
},
}

@ -10,6 +10,7 @@ return {
optional = true,
opts = function(_, opts)
local nls = require("null-ls")
opts.sources = opts.sources or {}
table.insert(opts.sources, nls.builtins.formatting.prettierd)
end,
},

@ -12,8 +12,7 @@ return {
optional = true,
opts = function(_, opts)
local nls = require("null-ls")
opts.sources = opts.sources or {}
vim.list_extend(opts.sources, {
opts.sources = vim.list_extend(opts.sources or {}, {
nls.builtins.diagnostics.cmake_lint,
})
end,

@ -19,8 +19,7 @@ return {
optional = true,
opts = function(_, opts)
local nls = require("null-ls")
opts.sources = opts.sources or {}
vim.list_extend(opts.sources, {
opts.sources = vim.list_extend(opts.sources or {}, {
nls.builtins.diagnostics.hadolint,
})
end,

@ -37,8 +37,7 @@ return {
return
end
local nls = require("null-ls")
opts.sources = opts.sources or {}
vim.list_extend(opts.sources, {
opts.sources = vim.list_extend(opts.sources or {}, {
nls.builtins.diagnostics.credo,
})
end,

@ -61,7 +61,7 @@ return {
gopls = function(_, opts)
-- workaround for gopls not supporting semanticTokensProvider
-- https://github.com/golang/go/issues/54531#issuecomment-1464982242
require("lazyvim.util").on_attach(function(client, _)
require("lazyvim.util").lsp.on_attach(function(client, _)
if client.name == "gopls" then
if not client.server_capabilities.semanticTokensProvider then
local semantic = client.config.capabilities.textDocument.semanticTokens
@ -82,18 +82,33 @@ return {
},
},
-- Ensure Go tools are installed
{
"williamboman/mason.nvim",
opts = function(_, opts)
opts.ensure_installed = opts.ensure_installed or {}
vim.list_extend(opts.ensure_installed, { "goimports", "gofumpt" })
end,
},
{
"nvimtools/none-ls.nvim",
optional = true,
dependencies = {
{
"williamboman/mason.nvim",
opts = function(_, opts)
opts.ensure_installed = opts.ensure_installed or {}
vim.list_extend(opts.ensure_installed, { "gomodifytags", "impl" })
end,
},
},
opts = function(_, opts)
if type(opts.sources) == "table" then
local nls = require("null-ls")
vim.list_extend(opts.sources, {
nls.builtins.code_actions.gomodifytags,
nls.builtins.code_actions.impl,
nls.builtins.formatting.goimports,
})
end
local nls = require("null-ls")
opts.sources = vim.list_extend(opts.sources or {}, {
nls.builtins.code_actions.gomodifytags,
nls.builtins.code_actions.impl,
nls.builtins.formatting.goimports,
nls.builtins.formatting.gofumpt,
})
end,
},
{
@ -101,7 +116,7 @@ return {
optional = true,
opts = {
formatters_by_ft = {
go = { "goimports" },
go = { "goimports", "gofumpt" },
},
},
},
@ -110,10 +125,10 @@ return {
optional = true,
dependencies = {
{
"mason.nvim",
"williamboman/mason.nvim",
opts = function(_, opts)
opts.ensure_installed = opts.ensure_installed or {}
vim.list_extend(opts.ensure_installed, { "gomodifytags", "impl", "goimports", "delve" })
vim.list_extend(opts.ensure_installed, { "delve" })
end,
},
{

@ -0,0 +1,64 @@
return {
{
"nvim-treesitter/nvim-treesitter",
opts = function(_, opts)
if type(opts.ensure_installed) == "table" then
vim.list_extend(opts.ensure_installed, { "markdown", "markdown_inline" })
end
end,
},
{
"williamboman/mason.nvim",
opts = function(_, opts)
opts.ensure_installed = opts.ensure_installed or {}
vim.list_extend(opts.ensure_installed, { "markdownlint" })
end,
},
{
"nvimtools/none-ls.nvim",
optional = true,
opts = function(_, opts)
local nls = require("null-ls")
opts.sources = vim.list_extend(opts.sources or {}, {
nls.builtins.diagnostics.markdownlint,
})
end,
},
{
"mfussenegger/nvim-lint",
optional = true,
opts = {
linters_by_ft = {
markdown = { "markdownlint" },
},
},
},
{
"neovim/nvim-lspconfig",
opts = {
servers = {
marksman = {},
},
},
},
-- Markdown preview
{
"iamcco/markdown-preview.nvim",
cmd = { "MarkdownPreviewToggle", "MarkdownPreview", "MarkdownPreviewStop" },
build = function()
vim.fn["mkdp#util#install"]()
end,
keys = {
{
"<leader>cp",
ft = "markdown",
"<cmd>MarkdownPreviewToggle<cr>",
desc = "Peek (Markdown Preview)",
},
},
config = function()
vim.cmd([[do FileType]])
end,
},
}

@ -13,6 +13,7 @@ return {
optional = true,
opts = function(_, opts)
local nls = require("null-ls")
opts.sources = opts.sources or {}
table.insert(opts.sources, nls.builtins.formatting.csharpier)
end,
},

@ -12,11 +12,27 @@ return {
opts = {
servers = {
pyright = {},
ruff_lsp = {},
ruff_lsp = {
keys = {
{
"<leader>co",
function()
vim.lsp.buf.code_action({
apply = true,
context = {
only = { "source.organizeImports" },
diagnostics = {},
},
})
end,
desc = "Organize Imports",
},
},
},
},
setup = {
ruff_lsp = function()
require("lazyvim.util").on_attach(function(client, _)
require("lazyvim.util").lsp.on_attach(function(client, _)
if client.name == "ruff_lsp" then
-- Disable hover in favor of Pyright
client.server_capabilities.hoverProvider = false

@ -28,13 +28,11 @@ return {
"nvimtools/none-ls.nvim",
optional = true,
opts = function(_, opts)
if type(opts.sources) == "table" then
local null_ls = require("null-ls")
vim.list_extend(opts.sources, {
null_ls.builtins.formatting.terraform_fmt,
null_ls.builtins.diagnostics.terraform_validate,
})
end
local null_ls = require("null-ls")
opts.sources = vim.list_extend(opts.sources or {}, {
null_ls.builtins.formatting.terraform_fmt,
null_ls.builtins.diagnostics.terraform_validate,
})
end,
},
{

@ -64,7 +64,7 @@ return {
yamlls = function()
-- Neovim < 0.10 does not have dynamic registration for formatting
if vim.fn.has("nvim-0.10") == 0 then
require("lazyvim.util").on_attach(function(client, _)
require("lazyvim.util").lsp.on_attach(function(client, _)
if client.name == "yamlls" then
client.server_capabilities.documentFormattingProvider = true
end

@ -14,22 +14,37 @@ return {
},
setup = {
eslint = function()
vim.api.nvim_create_autocmd("BufWritePre", {
callback = function(event)
if not require("lazyvim.plugins.lsp.format").enabled() then
-- exit early if autoformat is not enabled
return
end
local function get_client(buf)
return require("lazyvim.util").lsp.get_clients({ name = "eslint", bufnr = buf })[1]
end
local client = require("lazyvim.util").get_clients({ bufnr = event.buf, name = "eslint" })[1]
local formatter = require("lazyvim.util").lsp.formatter({
name = "eslint: lsp",
primary = false,
priority = 200,
filter = "eslint",
})
-- Use EslintFixAll on Neovim < 0.10.0
if not pcall(require, "vim.lsp._dynamic") then
formatter.name = "eslint: EslintFixAll"
formatter.sources = function(buf)
local client = get_client(buf)
return client and { "eslint" } or {}
end
formatter.format = function(buf)
local client = get_client(buf)
if client then
local diag = vim.diagnostic.get(event.buf, { namespace = vim.lsp.diagnostic.get_namespace(client.id) })
local diag = vim.diagnostic.get(buf, { namespace = vim.lsp.diagnostic.get_namespace(client.id) })
if #diag > 0 then
vim.cmd("EslintFixAll")
end
end
end,
})
end
end
-- register the formatter with LazyVim
require("lazyvim.util").format.register(formatter)
end,
},
},

Some files were not shown because too many files have changed in this diff Show More