From 8a89c0360e4a076b99b09fe673fbd947f71577fc Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 18 Jun 2024 17:28:50 +0200 Subject: [PATCH 01/28] chore(main): release 12.17.0 (#3689) :robot: I have created a release *beep* *boop* --- ## [12.17.0](https://github.com/LazyVim/LazyVim/compare/v12.16.0...v12.17.0) (2024-06-18) ### Features * **copilot-chat:** ctrl-s now works in both normal and insert mode ([0fcadce](https://github.com/LazyVim/LazyVim/commit/0fcadced89f96f59a9f9cb0c85ee73990df1219f)) * **php:** allow using intelephense instead of phpactor in php extras ([#3691](https://github.com/LazyVim/LazyVim/issues/3691)) ([ea3b5cc](https://github.com/LazyVim/LazyVim/commit/ea3b5cc2ab4ff7d70163ab66ea7fa0acc0e88566)) * **treesitter-textobjects:** added ]a and [a to move between parameters ([18c7731](https://github.com/LazyVim/LazyVim/commit/18c7731281f7a9886ae98d9c034661fa85340fb2)) ### Bug Fixes * **cmp:** visible ([57ef349](https://github.com/LazyVim/LazyVim/commit/57ef349910ec40c7024f3b50a549aabefa1ebbf0)) * **conform:** `lsp_format` breaking changes ([#3707](https://github.com/LazyVim/LazyVim/issues/3707)) ([a69e626](https://github.com/LazyVim/LazyVim/commit/a69e626d7a3a027df124bae7b2672658a4fb5b0f)) * **edgy:** only enable edgy neo-tree when needed. Fixes [#3697](https://github.com/LazyVim/LazyVim/issues/3697). Closes [#3703](https://github.com/LazyVim/LazyVim/issues/3703) ([bdca1e9](https://github.com/LazyVim/LazyVim/commit/bdca1e95ff97348501a715bd6aa5977422a27969)) * **git:** removed debug info ([d9caee6](https://github.com/LazyVim/LazyVim/commit/d9caee610038548a4b79f2b6eb126180ec8ba6b6)) * **lazygit:** support monorepo structure and other git providers ([#3701](https://github.com/LazyVim/LazyVim/issues/3701)) ([1f034e1](https://github.com/LazyVim/LazyVim/commit/1f034e16000692d1d0ec8e02110d37cf2089bd4c)) * **lsp:** dont highlight document words when cmp is visible ([0d57115](https://github.com/LazyVim/LazyVim/commit/0d57115f01b4094f68e426942e14892f204ec664)) * **snippets:** nvim-snippets `<S-Tab>` prev key ([#3712](https://github.com/LazyVim/LazyVim/issues/3712)) ([492fa86](https://github.com/LazyVim/LazyVim/commit/492fa86faa29f2987f662ad0cdb796b5c1c49ef3)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- CHANGELOG.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e4d07691..e5e9e98c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,25 @@ # Changelog +## [12.17.0](https://github.com/LazyVim/LazyVim/compare/v12.16.0...v12.17.0) (2024-06-18) + + +### Features + +* **copilot-chat:** ctrl-s now works in both normal and insert mode ([0fcadce](https://github.com/LazyVim/LazyVim/commit/0fcadced89f96f59a9f9cb0c85ee73990df1219f)) +* **php:** allow using intelephense instead of phpactor in php extras ([#3691](https://github.com/LazyVim/LazyVim/issues/3691)) ([ea3b5cc](https://github.com/LazyVim/LazyVim/commit/ea3b5cc2ab4ff7d70163ab66ea7fa0acc0e88566)) +* **treesitter-textobjects:** added ]a and [a to move between parameters ([18c7731](https://github.com/LazyVim/LazyVim/commit/18c7731281f7a9886ae98d9c034661fa85340fb2)) + + +### Bug Fixes + +* **cmp:** visible ([57ef349](https://github.com/LazyVim/LazyVim/commit/57ef349910ec40c7024f3b50a549aabefa1ebbf0)) +* **conform:** `lsp_format` breaking changes ([#3707](https://github.com/LazyVim/LazyVim/issues/3707)) ([a69e626](https://github.com/LazyVim/LazyVim/commit/a69e626d7a3a027df124bae7b2672658a4fb5b0f)) +* **edgy:** only enable edgy neo-tree when needed. Fixes [#3697](https://github.com/LazyVim/LazyVim/issues/3697). Closes [#3703](https://github.com/LazyVim/LazyVim/issues/3703) ([bdca1e9](https://github.com/LazyVim/LazyVim/commit/bdca1e95ff97348501a715bd6aa5977422a27969)) +* **git:** removed debug info ([d9caee6](https://github.com/LazyVim/LazyVim/commit/d9caee610038548a4b79f2b6eb126180ec8ba6b6)) +* **lazygit:** support monorepo structure and other git providers ([#3701](https://github.com/LazyVim/LazyVim/issues/3701)) ([1f034e1](https://github.com/LazyVim/LazyVim/commit/1f034e16000692d1d0ec8e02110d37cf2089bd4c)) +* **lsp:** dont highlight document words when cmp is visible ([0d57115](https://github.com/LazyVim/LazyVim/commit/0d57115f01b4094f68e426942e14892f204ec664)) +* **snippets:** nvim-snippets `<S-Tab>` prev key ([#3712](https://github.com/LazyVim/LazyVim/issues/3712)) ([492fa86](https://github.com/LazyVim/LazyVim/commit/492fa86faa29f2987f662ad0cdb796b5c1c49ef3)) + ## [12.16.0](https://github.com/LazyVim/LazyVim/compare/v12.15.0...v12.16.0) (2024-06-16) From 1a295c5ef8cab02c6054067c35ca805a3e4ccf72 Mon Sep 17 00:00:00 2001 From: Iordanis Petkakis <12776461+dpetka2001@users.noreply.github.com> Date: Tue, 18 Jun 2024 19:42:34 +0300 Subject: [PATCH 02/28] fix(statuscolumn): `%r` deprecated in nightly and `%l` handles everything (#3719) ## What is this PR for? Fix correctly showing relative numbers in `statuscolumn` after recent breaking changes on [nightly](https://github.com/neovim/neovim/pull/29357). Please feel free to disregard this PR if a better solution is possible. ## Does this PR fix an existing issue? Fixes #3721 ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/util/ui.lua | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/lua/lazyvim/util/ui.lua b/lua/lazyvim/util/ui.lua index 1ad2b6f0..f14096db 100644 --- a/lua/lazyvim/util/ui.lua +++ b/lua/lazyvim/util/ui.lua @@ -140,10 +140,14 @@ function M.statuscolumn() local is_num = vim.wo[win].number local is_relnum = vim.wo[win].relativenumber if (is_num or is_relnum) and vim.v.virtnum == 0 then - if vim.v.relnum == 0 then - components[2] = is_num and "%l" or "%r" -- the current line + if vim.fn.has("nvim-0.11") == 1 then + components[2] = "%l" -- 0.11 handles both the current and other lines with %l else - components[2] = is_relnum and "%r" or "%l" -- other lines + if vim.v.relnum == 0 then + components[2] = is_num and "%l" or "%r" -- the current line + else + components[2] = is_relnum and "%r" or "%l" -- other lines + end end components[2] = "%=" .. components[2] .. " " -- right align end From 07ab681b1d6f0223e6b265f3eb6aaafbd12e5c0e Mon Sep 17 00:00:00 2001 From: xiaojianzheng <1272209235@qq.com> Date: Wed, 19 Jun 2024 00:47:40 +0800 Subject: [PATCH 03/28] feat(project): add fzf-lua keymap descriptions (#3690) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ![image](https://github.com/LazyVim/LazyVim/assets/29248764/17f36737-8416-4612-a2bf-17a264ca5814) Co-authored-by: 肖健正 --- lua/lazyvim/plugins/extras/util/project.lua | 100 ++++++++++++-------- 1 file changed, 63 insertions(+), 37 deletions(-) diff --git a/lua/lazyvim/plugins/extras/util/project.lua b/lua/lazyvim/plugins/extras/util/project.lua index c84b73bb..42958872 100644 --- a/lua/lazyvim/plugins/extras/util/project.lua +++ b/lua/lazyvim/plugins/extras/util/project.lua @@ -9,45 +9,71 @@ pick = function() local history = require("project_nvim.utils.history") local results = history.get_recent_projects() local actions = require("fzf-lua.actions") + local core = require("fzf-lua.core") + -- local path = require("fzf-lua.path") + local utils = require("fzf-lua.utils") - fzf_lua.fzf_exec(results, { - actions = { - ["default"] = { - function(selected) - fzf_lua.files({ cwd = selected[1] }) - end, - }, - ["ctrl-t"] = actions.file_tabedit, - ["ctrl-s"] = { - function(selected) - fzf_lua.live_grep({ cwd = selected[1] }) - end, - }, - ["ctrl-r"] = { - function(selected) - fzf_lua.oldfiles({ cwd = selected[1] }) - end, - }, - ["ctrl-w"] = { - function(selected) - local path = selected[1] - local ok = project.set_pwd(path) - if ok then - vim.api.nvim_feedkeys(vim.api.nvim_replace_termcodes("", true, false, true), "n", true) - LazyVim.info("Change project dir to " .. path) - end - end, - }, - ["ctrl-d"] = function(selected) - local path = selected[1] - local choice = vim.fn.confirm("Delete '" .. path .. "' project? ", "&Yes\n&No") - if choice == 1 then - history.delete_project({ value = path }) - end - pick() - end, + local function hl_validate(hl) + return not utils.is_hl_cleared(hl) and hl or nil + end + + function actions.project_files(selected) + fzf_lua.files({ cwd = selected[1] }) + end + + function actions.project_live_grep(selected) + fzf_lua.live_grep({ cwd = selected[1] }) + end + + function actions.project_oldfiles(selected) + fzf_lua.oldfiles({ cwd = selected[1] }) + end + + function actions.project_cd_cwd(selected) + local path = selected[1] + local ok = project.set_pwd(path) + if ok then + vim.api.nvim_feedkeys(vim.api.nvim_replace_termcodes("", true, false, true), "n", true) + LazyVim.info("Change project dir to " .. path) + end + end + + function actions.project_delete(selected) + local path = selected[1] + local choice = vim.fn.confirm("Delete '" .. path .. "' project? ", "&Yes\n&No") + if choice == 1 then + history.delete_project({ value = path }) + end + pick() + end + + -- core.ACTION_DEFINITIONS[actions.project_files] = { "find project files" } + core.ACTION_DEFINITIONS[actions.file_tabedit] = { "tabedit" } + core.ACTION_DEFINITIONS[actions.project_live_grep] = { "live_grep" } + core.ACTION_DEFINITIONS[actions.project_oldfiles] = { "oldfiles" } + core.ACTION_DEFINITIONS[actions.project_cd_cwd] = { "change dir" } + core.ACTION_DEFINITIONS[actions.project_delete] = { "delete" } + + local opts = { + fzf_opts = {}, + hls = { + header_bind = hl_validate("FzfLuaHeaderBind"), + header_text = hl_validate("FzfLuaHeaderText"), }, - }) + fzf_colors = true, + header_separator = " | ", + actions = { + ["default"] = actions.project_files, + ["ctrl-t"] = actions.file_tabedit, + ["ctrl-s"] = actions.project_live_grep, + ["ctrl-r"] = actions.project_oldfiles, + ["ctrl-w"] = actions.project_cd_cwd, + ["ctrl-d"] = actions.project_delete, + }, + } + + opts = core.set_header(opts, { "actions" }) + fzf_lua.fzf_exec(results, opts) end end From 06f13daf7261377ecfa6b4ac845d742f446df719 Mon Sep 17 00:00:00 2001 From: dbger <3982742+dbger@users.noreply.github.com> Date: Wed, 19 Jun 2024 01:02:41 +0800 Subject: [PATCH 04/28] fix(dap): get the correct debugpy pkg path on windows (#3716) ## What is this PR for? fix(dap): get the correct debugpy pkg path on windows. ## Does this PR fix an existing issue? ## Checklist - [ ] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/extras/lang/python.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/extras/lang/python.lua b/lua/lazyvim/plugins/extras/lang/python.lua index e328a51f..9aeca2a4 100644 --- a/lua/lazyvim/plugins/extras/lang/python.lua +++ b/lua/lazyvim/plugins/extras/lang/python.lua @@ -92,7 +92,11 @@ return { { "dPc", function() require('dap-python').test_class() end, desc = "Debug Class", ft = "python" }, }, config = function() - require("dap-python").setup(LazyVim.get_pkg_path("debugpy", "/venv/bin/python")) + if vim.fn.has("win32") == 1 then + require("dap-python").setup(LazyVim.get_pkg_path("debugpy", "/venv/Scripts/python.exe")) + else + require("dap-python").setup(LazyVim.get_pkg_path("debugpy", "/venv/bin/python")) + end end, }, }, From 1101c3ed24709feec85371a951ea0feed6bd50fa Mon Sep 17 00:00:00 2001 From: Ahmed Kamal Date: Wed, 19 Jun 2024 03:03:19 +1000 Subject: [PATCH 05/28] feat(extra): add prisma support and config (#3684) ## What is this PR for? Adding support for prisma ## Does this PR fix an existing issue? No ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --------- Co-authored-by: Ben Puryear <54869170+Ben10164@users.noreply.github.com> --- lua/lazyvim/plugins/extras/lang/prisma.lua | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 lua/lazyvim/plugins/extras/lang/prisma.lua diff --git a/lua/lazyvim/plugins/extras/lang/prisma.lua b/lua/lazyvim/plugins/extras/lang/prisma.lua new file mode 100644 index 00000000..f086d4ca --- /dev/null +++ b/lua/lazyvim/plugins/extras/lang/prisma.lua @@ -0,0 +1,21 @@ +return { + recommended = function() + return LazyVim.extras.wants({ + ft = "prisma", + }) + end, + { + "nvim-treesitter/nvim-treesitter", + opts = { + ensure_installed = { "prisma" }, + }, + }, + { + "neovim/nvim-lspconfig", + opts = { + servers = { + prismals = {}, + }, + }, + }, +} From 67eece6d74f071035ca7b934a753d71d1677dd9b Mon Sep 17 00:00:00 2001 From: Adam K <105152139+akthe-at@users.noreply.github.com> Date: Tue, 18 Jun 2024 14:31:41 -0500 Subject: [PATCH 06/28] fix(extras.python): avoid launching extra console with dap on Windows (#3723) On Windows, when using dap, python.exe will launch an extra console. If you target pythonw.exe this avoids that. Explanation source: https://stackoverflow.com/questions/9705982/pythonw-exe-or-python-exe ## What is this PR for? Modify which exe is targeted for python + dap on windows. If you use python.exe an extra console launches (eg, nvim is runnining on Wezterm, boot up dap, and as a result an external console (usually through windows terminal or built-in console terminal) will launch (dap still runs in the original window). This is avoided with pythonw.exe ## Does this PR fix an existing issue? No ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/extras/lang/python.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/extras/lang/python.lua b/lua/lazyvim/plugins/extras/lang/python.lua index 9aeca2a4..399f28e3 100644 --- a/lua/lazyvim/plugins/extras/lang/python.lua +++ b/lua/lazyvim/plugins/extras/lang/python.lua @@ -93,7 +93,7 @@ return { }, config = function() if vim.fn.has("win32") == 1 then - require("dap-python").setup(LazyVim.get_pkg_path("debugpy", "/venv/Scripts/python.exe")) + require("dap-python").setup(LazyVim.get_pkg_path("debugpy", "/venv/Scripts/pythonw.exe")) else require("dap-python").setup(LazyVim.get_pkg_path("debugpy", "/venv/bin/python")) end From d4991d5aac3c4ab5865e65d73fb8957b3d61bdc3 Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Wed, 19 Jun 2024 18:25:56 +0200 Subject: [PATCH 07/28] fix(root): also check root_dir. Fixes #3732 --- lua/lazyvim/util/root.lua | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lua/lazyvim/util/root.lua b/lua/lazyvim/util/root.lua index a401ccf4..fc81e92f 100644 --- a/lua/lazyvim/util/root.lua +++ b/lua/lazyvim/util/root.lua @@ -30,12 +30,13 @@ function M.detectors.lsp(buf) end local roots = {} ---@type string[] for _, client in pairs(LazyVim.lsp.get_clients({ bufnr = buf })) do - -- only check workspace folders, since we're not interested in clients - -- running in single file mode local workspace = client.config.workspace_folders for _, ws in pairs(workspace or {}) do roots[#roots + 1] = vim.uri_to_fname(ws.uri) end + if client.root_dir then + roots[#roots + 1] = client.root_dir + end end return vim.tbl_filter(function(path) path = LazyVim.norm(path) From 7afb7a7220b687b087652397cd6625f8ec783d0b Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 19 Jun 2024 16:26:34 +0000 Subject: [PATCH 08/28] chore(build): auto-generate vimdoc --- doc/LazyVim.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/LazyVim.txt b/doc/LazyVim.txt index 503edeea..24f3a019 100644 --- a/doc/LazyVim.txt +++ b/doc/LazyVim.txt @@ -1,4 +1,4 @@ -*LazyVim.txt* For Neovim >= 0.9.0 Last change: 2024 June 18 +*LazyVim.txt* For Neovim >= 0.9.0 Last change: 2024 June 19 ============================================================================== Table of Contents *LazyVim-table-of-contents* From dde4a9dcdf49719c67642d09847dbaf7f9c7a156 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 19 Jun 2024 22:52:18 +0200 Subject: [PATCH 09/28] chore(main): release 12.18.0 (#3722) :robot: I have created a release *beep* *boop* --- ## [12.18.0](https://github.com/LazyVim/LazyVim/compare/v12.17.0...v12.18.0) (2024-06-19) ### Features * **extra:** add prisma support and config ([#3684](https://github.com/LazyVim/LazyVim/issues/3684)) ([1101c3e](https://github.com/LazyVim/LazyVim/commit/1101c3ed24709feec85371a951ea0feed6bd50fa)) * **project:** add fzf-lua keymap descriptions ([#3690](https://github.com/LazyVim/LazyVim/issues/3690)) ([07ab681](https://github.com/LazyVim/LazyVim/commit/07ab681b1d6f0223e6b265f3eb6aaafbd12e5c0e)) ### Bug Fixes * **dap:** get the correct debugpy pkg path on windows ([#3716](https://github.com/LazyVim/LazyVim/issues/3716)) ([06f13da](https://github.com/LazyVim/LazyVim/commit/06f13daf7261377ecfa6b4ac845d742f446df719)) * **extras.python:** avoid launching extra console with dap on Windows ([#3723](https://github.com/LazyVim/LazyVim/issues/3723)) ([67eece6](https://github.com/LazyVim/LazyVim/commit/67eece6d74f071035ca7b934a753d71d1677dd9b)) * **root:** also check root_dir. Fixes [#3732](https://github.com/LazyVim/LazyVim/issues/3732) ([d4991d5](https://github.com/LazyVim/LazyVim/commit/d4991d5aac3c4ab5865e65d73fb8957b3d61bdc3)) * **statuscolumn:** `%r` deprecated in nightly and `%l` handles everything ([#3719](https://github.com/LazyVim/LazyVim/issues/3719)) ([1a295c5](https://github.com/LazyVim/LazyVim/commit/1a295c5ef8cab02c6054067c35ca805a3e4ccf72)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- CHANGELOG.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index e5e9e98c..2062fc48 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,21 @@ # Changelog +## [12.18.0](https://github.com/LazyVim/LazyVim/compare/v12.17.0...v12.18.0) (2024-06-19) + + +### Features + +* **extra:** add prisma support and config ([#3684](https://github.com/LazyVim/LazyVim/issues/3684)) ([1101c3e](https://github.com/LazyVim/LazyVim/commit/1101c3ed24709feec85371a951ea0feed6bd50fa)) +* **project:** add fzf-lua keymap descriptions ([#3690](https://github.com/LazyVim/LazyVim/issues/3690)) ([07ab681](https://github.com/LazyVim/LazyVim/commit/07ab681b1d6f0223e6b265f3eb6aaafbd12e5c0e)) + + +### Bug Fixes + +* **dap:** get the correct debugpy pkg path on windows ([#3716](https://github.com/LazyVim/LazyVim/issues/3716)) ([06f13da](https://github.com/LazyVim/LazyVim/commit/06f13daf7261377ecfa6b4ac845d742f446df719)) +* **extras.python:** avoid launching extra console with dap on Windows ([#3723](https://github.com/LazyVim/LazyVim/issues/3723)) ([67eece6](https://github.com/LazyVim/LazyVim/commit/67eece6d74f071035ca7b934a753d71d1677dd9b)) +* **root:** also check root_dir. Fixes [#3732](https://github.com/LazyVim/LazyVim/issues/3732) ([d4991d5](https://github.com/LazyVim/LazyVim/commit/d4991d5aac3c4ab5865e65d73fb8957b3d61bdc3)) +* **statuscolumn:** `%r` deprecated in nightly and `%l` handles everything ([#3719](https://github.com/LazyVim/LazyVim/issues/3719)) ([1a295c5](https://github.com/LazyVim/LazyVim/commit/1a295c5ef8cab02c6054067c35ca805a3e4ccf72)) + ## [12.17.0](https://github.com/LazyVim/LazyVim/compare/v12.16.0...v12.17.0) (2024-06-18) From b22831b7e25a4681df171da30204d4d4f7e9abfa Mon Sep 17 00:00:00 2001 From: Iordanis Petkakis <12776461+dpetka2001@users.noreply.github.com> Date: Fri, 21 Jun 2024 22:14:48 +0300 Subject: [PATCH 10/28] feat(gitsigns): new keymap for `Gitsigns blame` (#3758) Also add filetype `gitsigns.blame` to autocmd `lazyvim_close_with_q` and workaround for `+hunks` group name to show prefix correctly. If you don't like the workaround for `+hunks` group name feel free to remove it. ## What is this PR for? Make use of the new `gitsigns` feature `Gitsigns blame`, which shows in a vertical buffer split the `blame` history of the whole buffer. ## Does this PR fix an existing issue? No. ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/config/autocmds.lua | 1 + lua/lazyvim/plugins/editor.lua | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/lua/lazyvim/config/autocmds.lua b/lua/lazyvim/config/autocmds.lua index 2fc283ba..81d0209a 100644 --- a/lua/lazyvim/config/autocmds.lua +++ b/lua/lazyvim/config/autocmds.lua @@ -67,6 +67,7 @@ vim.api.nvim_create_autocmd("FileType", { "neotest-summary", "neotest-output-panel", "dbout", + "gitsigns.blame", }, callback = function(event) vim.bo[event.buf].buflisted = false diff --git a/lua/lazyvim/plugins/editor.lua b/lua/lazyvim/plugins/editor.lua index 05fe5c25..b80c0d8f 100644 --- a/lua/lazyvim/plugins/editor.lua +++ b/lua/lazyvim/plugins/editor.lua @@ -177,7 +177,7 @@ return { ["c"] = { name = "+code" }, ["f"] = { name = "+file/find" }, ["g"] = { name = "+git" }, - ["gh"] = { name = "+hunks" }, + ["gh"] = { name = "+hunks", ["_"] = "which_key_ignore" }, ["q"] = { name = "+quit/session" }, ["s"] = { name = "+search" }, ["u"] = { name = "+ui" }, @@ -226,6 +226,7 @@ return { map("n", "ghR", gs.reset_buffer, "Reset Buffer") map("n", "ghp", gs.preview_hunk_inline, "Preview Hunk Inline") map("n", "ghb", function() gs.blame_line({ full = true }) end, "Blame Line") + map("n", "ghB", function() gs.blame() end, "Blame Buffer") map("n", "ghd", gs.diffthis, "Diff This") map("n", "ghD", function() gs.diffthis("~") end, "Diff This ~") map({ "o", "x" }, "ih", ":Gitsigns select_hunk", "GitSigns Select Hunk") From b0274a2222752b809188e86101a96791a72e03bf Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Fri, 21 Jun 2024 19:15:24 +0000 Subject: [PATCH 11/28] chore(build): auto-generate vimdoc --- doc/LazyVim.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/LazyVim.txt b/doc/LazyVim.txt index 24f3a019..dc975714 100644 --- a/doc/LazyVim.txt +++ b/doc/LazyVim.txt @@ -1,4 +1,4 @@ -*LazyVim.txt* For Neovim >= 0.9.0 Last change: 2024 June 19 +*LazyVim.txt* For Neovim >= 0.9.0 Last change: 2024 June 21 ============================================================================== Table of Contents *LazyVim-table-of-contents* From b47c65f4087c4d82720ab7439f395aba5d6b5f40 Mon Sep 17 00:00:00 2001 From: Iordanis Petkakis <12776461+dpetka2001@users.noreply.github.com> Date: Fri, 21 Jun 2024 22:15:32 +0300 Subject: [PATCH 12/28] fix(statuscolumn): fix `folds_open = true` (#3756) After some recent changes in https://github.com/neovim/neovim/pull/28709 I was getting an error when the user had `folds_open = true` in his personal configuration whenever he pressed `o/O`. This is an attempt to fix that. ## What is this PR for? I was getting an error with `folds_open = true` in the user configuration whenever pressing `o/O` or pressing `Enter` for a new line. The error was `Error executing lua: ...e/jrn23/projects/plugins/LazyVim/lua/lazyvim/util/ui.lua:127: attempt to index a number value`. ## Does this PR fix an existing issue? No ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/util/ui.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/lazyvim/util/ui.lua b/lua/lazyvim/util/ui.lua index f14096db..6bb8a4f7 100644 --- a/lua/lazyvim/util/ui.lua +++ b/lua/lazyvim/util/ui.lua @@ -124,7 +124,7 @@ function M.statuscolumn() elseif show_open_folds and not LazyVim.ui.skip_foldexpr[buf] - and vim.treesitter.foldexpr(vim.v.lnum):sub(1, 1) == ">" + and tostring(vim.treesitter.foldexpr(vim.v.lnum)):sub(1, 1) == ">" then -- fold start fold = { text = vim.opt.fillchars:get().foldopen or "", texthl = githl } end From 3dfc2c0fd8f3abe5cece9d4479c42b41b46c399f Mon Sep 17 00:00:00 2001 From: Ben Elan Date: Sat, 22 Jun 2024 22:00:07 -0700 Subject: [PATCH 13/28] ci(release): fix version bumping in extra-file (#3772) ## What is this PR for? Fix release-please CI so the version in the `extra-file` is bumped. ## Does this PR fix an existing issue? No ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. ref: folke/lazy.nvim#1534 --------- Co-authored-by: github-actions[bot] --- .github/.release-please-manifest.json | 3 +++ .github/release-please-config.json | 9 +++++++++ .github/workflows/ci.yml | 3 ++- doc/LazyVim.txt | 2 +- release-please-config.json | 5 ----- 5 files changed, 15 insertions(+), 7 deletions(-) create mode 100644 .github/.release-please-manifest.json create mode 100644 .github/release-please-config.json delete mode 100644 release-please-config.json diff --git a/.github/.release-please-manifest.json b/.github/.release-please-manifest.json new file mode 100644 index 00000000..2a3d0770 --- /dev/null +++ b/.github/.release-please-manifest.json @@ -0,0 +1,3 @@ +{ + ".": "12.18.0" +} diff --git a/.github/release-please-config.json b/.github/release-please-config.json new file mode 100644 index 00000000..41fccb15 --- /dev/null +++ b/.github/release-please-config.json @@ -0,0 +1,9 @@ +{ + "$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json", + "packages": { + ".": { + "release-type": "simple", + "extra-files": ["lua/lazyvim/config/init.lua"] + } + } +} diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index fddf82ac..9040f5e0 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -67,7 +67,8 @@ jobs: - uses: googleapis/release-please-action@v4 id: release with: - release-type: simple + config-file: .github/release-please-config.json + manifest-file: .github/.release-please-manifest.json - uses: actions/checkout@v4 - name: tag stable versions if: ${{ steps.release.outputs.release_created }} diff --git a/doc/LazyVim.txt b/doc/LazyVim.txt index dc975714..7227a1d2 100644 --- a/doc/LazyVim.txt +++ b/doc/LazyVim.txt @@ -1,4 +1,4 @@ -*LazyVim.txt* For Neovim >= 0.9.0 Last change: 2024 June 21 +*LazyVim.txt* For Neovim >= 0.9.0 Last change: 2024 June 23 ============================================================================== Table of Contents *LazyVim-table-of-contents* diff --git a/release-please-config.json b/release-please-config.json deleted file mode 100644 index 1d1b8b1d..00000000 --- a/release-please-config.json +++ /dev/null @@ -1,5 +0,0 @@ -{ - "$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json", - "release-type": "simple", - "extra-files": ["lua/lazyvim/config/init.lua"] -} From 55464b77c6ae8f14306ce743bcb3c5c465af3d4f Mon Sep 17 00:00:00 2001 From: Fredrik Averpil Date: Sun, 23 Jun 2024 07:01:22 +0200 Subject: [PATCH 14/28] feat(go): switch to neotest-golang (#3749) ## What is this PR for? This PR switches [nvim-neotest/neotest-go](https://github.com/nvim-neotest/neotest-go) for [fredrikaverpil/neotest-golang](https://github.com/fredrikaverpil/neotest-golang). ## Does this PR fix an existing issue? Neotest-go comes with some problems which are mitigated in neotest-golang. A full description/background is available in the project README, but here are some highlights: ### Neotest-go issues mitigated in neotest-golang - Test Output in JSON, making it difficult to read: [neotest-go#52](https://github.com/nvim-neotest/neotest-go/issues/52) - "Run nearest" runs all tests: [neotest-go#83](https://github.com/nvim-neotest/neotest-go/issues/83) - Running test suite doesn't work: [neotest-go#89](https://github.com/nvim-neotest/neotest-go/issues/89) - Diagnostics for table tests on the line of failure: [neotest-go#75](https://github.com/nvim-neotest/neotest-go/issues/75) - Support for Nested Subtests: [neotest-go#74](https://github.com/nvim-neotest/neotest-go/issues/74) - DAP support: [neotest-go#12](https://github.com/nvim-neotest/neotest-go/issues/12) ### Features - Supports all [Neotest usage](https://github.com/nvim-neotest/neotest#usage). - Integrates with [nvim-dap-go](https://github.com/leoluz/nvim-dap-go) for debugging of tests using delve. - Inline diagnostics. - Works great with [andythigpen/nvim-coverage](https://github.com/andythigpen/nvim-coverage) for displaying coverage in the sign column (per-Go package, or per-test basis). - Monorepo support (detect, run and debug tests in sub-projects). - Supports table tests (relies on treesitter AST detection). - Supports nested test functions. ## Notes - I'm the author of [fredrikaverpil/neotest-golang](https://github.com/fredrikaverpil/neotest-golang). ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/extras/lang/go.lua | 14 +++++--------- lua/lazyvim/plugins/extras/test/core.lua | 7 ++++--- 2 files changed, 9 insertions(+), 12 deletions(-) diff --git a/lua/lazyvim/plugins/extras/lang/go.lua b/lua/lazyvim/plugins/extras/lang/go.lua index 58c48643..931f8df4 100644 --- a/lua/lazyvim/plugins/extras/lang/go.lua +++ b/lua/lazyvim/plugins/extras/lang/go.lua @@ -14,10 +14,6 @@ return { opts = { servers = { gopls = { - keys = { - -- Workaround for the lack of a DAP strategy in neotest-go: https://github.com/nvim-neotest/neotest-go/issues/12 - { "td", "lua require('dap-go').debug_test()", desc = "Debug Nearest (Go)" }, - }, settings = { gopls = { gofumpt = true, @@ -129,14 +125,14 @@ return { "nvim-neotest/neotest", optional = true, dependencies = { - "nvim-neotest/neotest-go", + "fredrikaverpil/neotest-golang", }, opts = { adapters = { - ["neotest-go"] = { - -- Here we can set options for neotest-go, e.g. - -- args = { "-tags=integration" } - recursive_run = true, + ["neotest-golang"] = { + -- Here we can set options for neotest-golang, e.g. + -- go_test_args = { "-v", "-race", "-count=1", "-timeout=60s" }, + dap_go_enabled = true, -- requires leoluz/nvim-dap-go }, }, }, diff --git a/lua/lazyvim/plugins/extras/test/core.lua b/lua/lazyvim/plugins/extras/test/core.lua index dd7c7640..cab47ee9 100644 --- a/lua/lazyvim/plugins/extras/test/core.lua +++ b/lua/lazyvim/plugins/extras/test/core.lua @@ -10,10 +10,11 @@ return { -- or a table of adapter names, mapped to adapter configs. -- The adapter will then be automatically loaded with the config. adapters = {}, - -- Example for loading neotest-go with a custom config + -- Example for loading neotest-golang with a custom config -- adapters = { - -- ["neotest-go"] = { - -- args = { "-tags=integration" }, + -- ["neotest-golang"] = { + -- go_test_args = { "-v", "-race", "-count=1", "-timeout=60s" }, + -- dap_go_enabled = true, -- }, -- }, status = { virtual_text = true }, From b45d4ed62c613a4c47dd9183cf51985f2b153b21 Mon Sep 17 00:00:00 2001 From: Iordanis Petkakis <12776461+dpetka2001@users.noreply.github.com> Date: Sun, 23 Jun 2024 08:01:58 +0300 Subject: [PATCH 15/28] fix(refactoring): use `pick` for both Telescope and fzf-lua (#3769) ## What is this PR for? Provide a `pick` function to `refactoring.nvim` similar to `project.nvim` ## Does this PR fix an existing issue? Fixes #3762 ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- .../plugins/extras/editor/refactoring.lua | 25 ++++++++++++++++--- 1 file changed, 22 insertions(+), 3 deletions(-) diff --git a/lua/lazyvim/plugins/extras/editor/refactoring.lua b/lua/lazyvim/plugins/extras/editor/refactoring.lua index 9d8f8f9c..29920347 100644 --- a/lua/lazyvim/plugins/extras/editor/refactoring.lua +++ b/lua/lazyvim/plugins/extras/editor/refactoring.lua @@ -1,3 +1,24 @@ +local pick = function() + if LazyVim.pick.picker.name == "telescope" then + return require("telescope").extensions.refactoring.refactors() + elseif LazyVim.pick.picker.name == "fzf" then + local fzf_lua = require("fzf-lua") + local results = require("refactoring").get_refactors() + local refactoring = require("refactoring") + + local opts = { + fzf_opts = {}, + fzf_colors = true, + actions = { + ["default"] = function(selected) + refactoring.refactor(selected[1]) + end, + }, + } + fzf_lua.fzf_exec(results, opts) + end +end + return { { "ThePrimeagen/refactoring.nvim", @@ -10,9 +31,7 @@ return { { "r", "", desc = "+refactor", mode = { "n", "v" } }, { "rs", - function() - require("telescope").extensions.refactoring.refactors() - end, + pick, mode = "v", desc = "Refactor", }, From 19e366277b0f95c74cc90fe6f769691a3c6677c0 Mon Sep 17 00:00:00 2001 From: Gobinda Goshwami Date: Sun, 23 Jun 2024 11:08:41 +0600 Subject: [PATCH 16/28] refactor(extras.ui): simplify neo-tree related logic in edgy extra (#3738) Refactor neo-tree related logic ## What is this PR for? Simplification of `neo-tree` related logic in `edgy.lua` ## Does this PR fix an existing issue? No, but it may prevent future issues with `edgy` if `neo-tree` source configuration changes. ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/extras/ui/edgy.lua | 55 ++++++++++---------------- 1 file changed, 20 insertions(+), 35 deletions(-) diff --git a/lua/lazyvim/plugins/extras/ui/edgy.lua b/lua/lazyvim/plugins/extras/ui/edgy.lua index bdafb662..16b712e2 100644 --- a/lua/lazyvim/plugins/extras/ui/edgy.lua +++ b/lua/lazyvim/plugins/extras/ui/edgy.lua @@ -77,42 +77,27 @@ return { } if LazyVim.has("neo-tree.nvim") then - table.insert(opts.left, 1, { - title = "Neo-Tree", - ft = "neo-tree", - filter = function(buf) - return vim.b[buf].neo_tree_source == "filesystem" - end, - pinned = true, - open = function() - require("neo-tree.command").execute({ dir = LazyVim.root() }) - end, - size = { height = 0.5 }, - }) - -- only add neo-tree sources if they are enabled in config - local neotree_opts = LazyVim.opts("neo-tree.nvim") - local neotree_sources = { buffers = "top", git_status = "right" } - - for source, pos in pairs(neotree_sources) do - if vim.list_contains(neotree_opts.sources or {}, source) then - table.insert(opts.left, { - title = "Neo-Tree " .. source:gsub("_", " "), - ft = "neo-tree", - filter = function(buf) - return vim.b[buf].neo_tree_source == source - end, - pinned = true, - open = "Neotree position=" .. pos .. " " .. source, - }) - end + local pos = { + filesystem = "left", + buffers = "top", + git_status = "right", + document_symbols = "bottom", + diagnostics = "bottom", + } + local sources = LazyVim.opts("neo-tree.nvim").sources or {} + for i, v in ipairs(sources) do + table.insert(opts.left, i, { + title = "Neo-Tree " .. v:gsub("_", " "):gsub("^%l", string.upper), + ft = "neo-tree", + filter = function(buf) + return vim.b[buf].neo_tree_source == v + end, + pinned = true, + open = function() + vim.cmd(("Neotree show position=%s %s dir=%s"):format(pos[v] or "bottom", v, LazyVim.root())) + end, + }) end - table.insert(opts.left, { - title = "Neo-Tree Other", - ft = "neo-tree", - filter = function(buf) - return vim.b[buf].neo_tree_source ~= nil - end, - }) end for _, pos in ipairs({ "top", "bottom", "left", "right" }) do From 52d46166b14a9e99509c509482d9a0979fa00809 Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Sun, 23 Jun 2024 07:11:55 +0200 Subject: [PATCH 17/28] fix(neo-tree): don't enable document symbols by default --- lua/lazyvim/plugins/editor.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/editor.lua b/lua/lazyvim/plugins/editor.lua index b80c0d8f..1316ce76 100644 --- a/lua/lazyvim/plugins/editor.lua +++ b/lua/lazyvim/plugins/editor.lua @@ -60,7 +60,7 @@ return { }) end, opts = { - sources = { "filesystem", "buffers", "git_status", "document_symbols" }, + sources = { "filesystem", "buffers", "git_status" }, open_files_do_not_replace_types = { "terminal", "Trouble", "trouble", "qf", "Outline" }, filesystem = { bind_to_cwd = false, From 1f423930e03078eb1a2786356a46287c8a466c91 Mon Sep 17 00:00:00 2001 From: Brian Di Palma <1597820+briandipalma@users.noreply.github.com> Date: Sun, 23 Jun 2024 06:13:51 +0100 Subject: [PATCH 18/28] feat(gitsigns): navigate diff changes as well as git hunks with [h/]h (#3736) ## What is this PR for? I'm used to jumping from git hunks with `[h` so I'd like to use the same mapping when navigating diffs. ## Does this PR fix an existing issue? No ## Checklist - [X] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/editor.lua | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/lua/lazyvim/plugins/editor.lua b/lua/lazyvim/plugins/editor.lua index 1316ce76..f559c699 100644 --- a/lua/lazyvim/plugins/editor.lua +++ b/lua/lazyvim/plugins/editor.lua @@ -215,8 +215,20 @@ return { end -- stylua: ignore start - map("n", "]h", function() gs.nav_hunk("next") end, "Next Hunk") - map("n", "[h", function() gs.nav_hunk("prev") end, "Prev Hunk") + map("n", "]h", function() + if vim.wo.diff then + vim.cmd.normal({ "]c", bang = true }) + else + gs.nav_hunk("next") + end + end, "Next Hunk") + map("n", "[h", function() + if vim.wo.diff then + vim.cmd.normal({ "[c", bang = true }) + else + gs.nav_hunk("prev") + end + end, "Prev Hunk") map("n", "]H", function() gs.nav_hunk("last") end, "Last Hunk") map("n", "[H", function() gs.nav_hunk("first") end, "First Hunk") map({ "n", "v" }, "ghs", ":Gitsigns stage_hunk", "Stage Hunk") From 002ce62413e47c278525d7e092c205b2c850ece1 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 23 Jun 2024 07:38:34 +0200 Subject: [PATCH 19/28] chore(main): release 12.19.0 (#3760) :robot: I have created a release *beep* *boop* --- ## [12.19.0](https://github.com/LazyVim/LazyVim/compare/v12.18.0...v12.19.0) (2024-06-23) ### Features * **gitsigns:** navigate diff changes as well as git hunks with [h/]h ([#3736](https://github.com/LazyVim/LazyVim/issues/3736)) ([1f42393](https://github.com/LazyVim/LazyVim/commit/1f423930e03078eb1a2786356a46287c8a466c91)) * **gitsigns:** new keymap for `Gitsigns blame` ([#3758](https://github.com/LazyVim/LazyVim/issues/3758)) ([b22831b](https://github.com/LazyVim/LazyVim/commit/b22831b7e25a4681df171da30204d4d4f7e9abfa)) * **go:** switch to neotest-golang ([#3749](https://github.com/LazyVim/LazyVim/issues/3749)) ([55464b7](https://github.com/LazyVim/LazyVim/commit/55464b77c6ae8f14306ce743bcb3c5c465af3d4f)) ### Bug Fixes * **neo-tree:** don't enable document symbols by default ([52d4616](https://github.com/LazyVim/LazyVim/commit/52d46166b14a9e99509c509482d9a0979fa00809)) * **refactoring:** use `pick` for both Telescope and fzf-lua ([#3769](https://github.com/LazyVim/LazyVim/issues/3769)) ([b45d4ed](https://github.com/LazyVim/LazyVim/commit/b45d4ed62c613a4c47dd9183cf51985f2b153b21)) * **statuscolumn:** fix `folds_open = true` ([#3756](https://github.com/LazyVim/LazyVim/issues/3756)) ([b47c65f](https://github.com/LazyVim/LazyVim/commit/b47c65f4087c4d82720ab7439f395aba5d6b5f40)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- .github/.release-please-manifest.json | 2 +- CHANGELOG.md | 16 ++++++++++++++++ lua/lazyvim/config/init.lua | 2 +- 3 files changed, 18 insertions(+), 2 deletions(-) diff --git a/.github/.release-please-manifest.json b/.github/.release-please-manifest.json index 2a3d0770..6b671a44 100644 --- a/.github/.release-please-manifest.json +++ b/.github/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "12.18.0" + ".": "12.19.0" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 2062fc48..864b86ee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,21 @@ # Changelog +## [12.19.0](https://github.com/LazyVim/LazyVim/compare/v12.18.0...v12.19.0) (2024-06-23) + + +### Features + +* **gitsigns:** navigate diff changes as well as git hunks with [h/]h ([#3736](https://github.com/LazyVim/LazyVim/issues/3736)) ([1f42393](https://github.com/LazyVim/LazyVim/commit/1f423930e03078eb1a2786356a46287c8a466c91)) +* **gitsigns:** new keymap for `Gitsigns blame` ([#3758](https://github.com/LazyVim/LazyVim/issues/3758)) ([b22831b](https://github.com/LazyVim/LazyVim/commit/b22831b7e25a4681df171da30204d4d4f7e9abfa)) +* **go:** switch to neotest-golang ([#3749](https://github.com/LazyVim/LazyVim/issues/3749)) ([55464b7](https://github.com/LazyVim/LazyVim/commit/55464b77c6ae8f14306ce743bcb3c5c465af3d4f)) + + +### Bug Fixes + +* **neo-tree:** don't enable document symbols by default ([52d4616](https://github.com/LazyVim/LazyVim/commit/52d46166b14a9e99509c509482d9a0979fa00809)) +* **refactoring:** use `pick` for both Telescope and fzf-lua ([#3769](https://github.com/LazyVim/LazyVim/issues/3769)) ([b45d4ed](https://github.com/LazyVim/LazyVim/commit/b45d4ed62c613a4c47dd9183cf51985f2b153b21)) +* **statuscolumn:** fix `folds_open = true` ([#3756](https://github.com/LazyVim/LazyVim/issues/3756)) ([b47c65f](https://github.com/LazyVim/LazyVim/commit/b47c65f4087c4d82720ab7439f395aba5d6b5f40)) + ## [12.18.0](https://github.com/LazyVim/LazyVim/compare/v12.17.0...v12.18.0) (2024-06-19) diff --git a/lua/lazyvim/config/init.lua b/lua/lazyvim/config/init.lua index de41ec8c..e0825676 100644 --- a/lua/lazyvim/config/init.lua +++ b/lua/lazyvim/config/init.lua @@ -3,7 +3,7 @@ _G.LazyVim = require("lazyvim.util") ---@class LazyVimConfig: LazyVimOptions local M = {} -M.version = "10.21.1" -- x-release-please-version +M.version = "12.19.0" -- x-release-please-version LazyVim.config = M ---@class LazyVimOptions From abec8fbb03bdbe881c35401274083f315025a1ed Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Sun, 23 Jun 2024 08:56:15 +0200 Subject: [PATCH 20/28] fix(markdown): added support for mdx files --- lua/lazyvim/plugins/extras/lang/markdown.lua | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/extras/lang/markdown.lua b/lua/lazyvim/plugins/extras/lang/markdown.lua index 0b1c08a8..856d3ab6 100644 --- a/lua/lazyvim/plugins/extras/lang/markdown.lua +++ b/lua/lazyvim/plugins/extras/lang/markdown.lua @@ -1,7 +1,10 @@ +vim.filetype.add({ + extension = { mdx = "markdown.mdx" }, +}) return { recommended = function() return LazyVim.extras.wants({ - ft = "markdown", + ft = { "markdown", "markdown.mdx" }, root = "README.md", }) end, From 8ea3f690e6017ba37022060a62f1d69fbf3aeaf7 Mon Sep 17 00:00:00 2001 From: Iordanis Petkakis <12776461+dpetka2001@users.noreply.github.com> Date: Sun, 23 Jun 2024 16:38:27 +0300 Subject: [PATCH 21/28] fix(lazygit): use `lazy.util.open` on Neovim <= 0.10 (#3778) ## What is this PR for? Use `lazy.util.open` on Neovim <=0.10 ## Does this PR fix an existing issue? Closes #3776 ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/util/lazygit.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lua/lazyvim/util/lazygit.lua b/lua/lazyvim/util/lazygit.lua index c9ac1bb8..d69941df 100644 --- a/lua/lazyvim/util/lazygit.lua +++ b/lua/lazyvim/util/lazygit.lua @@ -176,6 +176,10 @@ function M.browse() local function open(remote) if remote then LazyVim.info(("Opening [%s](%s)"):format(remote.name, remote.url)) + if vim.fn.has("nvim-0.10") == 0 then + require("lazy.util").open(remote.url, { system = true }) + return + end vim.ui.open(remote.url) end end From b55c7734df72ff06659c16f5f9ed27b6b7199d44 Mon Sep 17 00:00:00 2001 From: Iordanis Petkakis <12776461+dpetka2001@users.noreply.github.com> Date: Sun, 23 Jun 2024 21:04:51 +0300 Subject: [PATCH 22/28] fix(dap): only load `mason-nvim-dap` when not disabled (#3784) ## What is this PR for? Only `require("mason-nvim-dap")` when it's not disabled ## Does this PR fix an existing issue? Fixes #3783 ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/extras/dap/core.lua | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/extras/dap/core.lua b/lua/lazyvim/plugins/extras/dap/core.lua index 045fb022..ac6709f1 100644 --- a/lua/lazyvim/plugins/extras/dap/core.lua +++ b/lua/lazyvim/plugins/extras/dap/core.lua @@ -49,7 +49,9 @@ return { config = function() -- load mason-nvim-dap here, after all adapters have been setup - require("mason-nvim-dap").setup(LazyVim.opts("mason-nvim-dap.nvim")) + if LazyVim.has("mason-nvim-dap.nvim") then + require("mason-nvim-dap").setup(LazyVim.opts("mason-nvim-dap.nvim")) + end vim.api.nvim_set_hl(0, "DapStoppedLine", { default = true, link = "Visual" }) From 8be66bb1a62aae97552032926fdcc101867b2028 Mon Sep 17 00:00:00 2001 From: Sandeep Dilip <34922961+sanman1k98@users.noreply.github.com> Date: Sun, 23 Jun 2024 16:19:47 -0400 Subject: [PATCH 23/28] fix(extras.astro): support `astro.config.ts` root (#3786) ## What is this PR for? Support [`astro.config.ts`](https://docs.astro.build/en/guides/configuring-astro/#supported-config-file-types) as a root file for the Astro extra. ## Does this PR fix an existing issue? N/A ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/extras/lang/astro.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lua/lazyvim/plugins/extras/lang/astro.lua b/lua/lazyvim/plugins/extras/lang/astro.lua index a4384148..1364902b 100644 --- a/lua/lazyvim/plugins/extras/lang/astro.lua +++ b/lua/lazyvim/plugins/extras/lang/astro.lua @@ -3,9 +3,11 @@ return { return LazyVim.extras.wants({ ft = "astro", root = { + -- https://docs.astro.build/en/guides/configuring-astro/#supported-config-file-types "astro.config.js", "astro.config.mjs", "astro.config.cjs", + "astro.config.ts", }, }) end, From 2a7ba6d09ce85fa752c25e68ca5287e24b8cee75 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 23 Jun 2024 22:24:44 +0200 Subject: [PATCH 24/28] chore(main): release 12.19.1 (#3775) :robot: I have created a release *beep* *boop* --- ## [12.19.1](https://github.com/LazyVim/LazyVim/compare/v12.19.0...v12.19.1) (2024-06-23) ### Bug Fixes * **dap:** only load `mason-nvim-dap` when not disabled ([#3784](https://github.com/LazyVim/LazyVim/issues/3784)) ([b55c773](https://github.com/LazyVim/LazyVim/commit/b55c7734df72ff06659c16f5f9ed27b6b7199d44)) * **extras.astro:** support `astro.config.ts` root ([#3786](https://github.com/LazyVim/LazyVim/issues/3786)) ([8be66bb](https://github.com/LazyVim/LazyVim/commit/8be66bb1a62aae97552032926fdcc101867b2028)) * **lazygit:** use `lazy.util.open` on Neovim <= 0.10 ([#3778](https://github.com/LazyVim/LazyVim/issues/3778)) ([8ea3f69](https://github.com/LazyVim/LazyVim/commit/8ea3f690e6017ba37022060a62f1d69fbf3aeaf7)) * **markdown:** added support for mdx files ([abec8fb](https://github.com/LazyVim/LazyVim/commit/abec8fbb03bdbe881c35401274083f315025a1ed)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> --- .github/.release-please-manifest.json | 2 +- CHANGELOG.md | 10 ++++++++++ lua/lazyvim/config/init.lua | 2 +- 3 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/.release-please-manifest.json b/.github/.release-please-manifest.json index 6b671a44..6231a550 100644 --- a/.github/.release-please-manifest.json +++ b/.github/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "12.19.0" + ".": "12.19.1" } diff --git a/CHANGELOG.md b/CHANGELOG.md index 864b86ee..a59494db 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,15 @@ # Changelog +## [12.19.1](https://github.com/LazyVim/LazyVim/compare/v12.19.0...v12.19.1) (2024-06-23) + + +### Bug Fixes + +* **dap:** only load `mason-nvim-dap` when not disabled ([#3784](https://github.com/LazyVim/LazyVim/issues/3784)) ([b55c773](https://github.com/LazyVim/LazyVim/commit/b55c7734df72ff06659c16f5f9ed27b6b7199d44)) +* **extras.astro:** support `astro.config.ts` root ([#3786](https://github.com/LazyVim/LazyVim/issues/3786)) ([8be66bb](https://github.com/LazyVim/LazyVim/commit/8be66bb1a62aae97552032926fdcc101867b2028)) +* **lazygit:** use `lazy.util.open` on Neovim <= 0.10 ([#3778](https://github.com/LazyVim/LazyVim/issues/3778)) ([8ea3f69](https://github.com/LazyVim/LazyVim/commit/8ea3f690e6017ba37022060a62f1d69fbf3aeaf7)) +* **markdown:** added support for mdx files ([abec8fb](https://github.com/LazyVim/LazyVim/commit/abec8fbb03bdbe881c35401274083f315025a1ed)) + ## [12.19.0](https://github.com/LazyVim/LazyVim/compare/v12.18.0...v12.19.0) (2024-06-23) diff --git a/lua/lazyvim/config/init.lua b/lua/lazyvim/config/init.lua index e0825676..23d4d63c 100644 --- a/lua/lazyvim/config/init.lua +++ b/lua/lazyvim/config/init.lua @@ -3,7 +3,7 @@ _G.LazyVim = require("lazyvim.util") ---@class LazyVimConfig: LazyVimOptions local M = {} -M.version = "12.19.0" -- x-release-please-version +M.version = "12.19.1" -- x-release-please-version LazyVim.config = M ---@class LazyVimOptions From b5945c2fc8cbb531983c7ec27d283ad8abf1acec Mon Sep 17 00:00:00 2001 From: Iordanis Petkakis <12776461+dpetka2001@users.noreply.github.com> Date: Mon, 24 Jun 2024 23:11:32 +0300 Subject: [PATCH 25/28] fix(fzf): disable `preview` for `vtsls` (#3798) ## What is this PR for? Disable `preview` in `fzf-lua` Extra for `vtsls`. I tested it with Python and Typescript Extras and in Typescript pressing `ca` shows without previewer, while in Python the same shows with previewer. Kindly check also that this is correct and I didn't miss out anything else. ## Does this PR fix an existing issue? Fixes #3773 ## Checklist - [x] I've read the [CONTRIBUTING](https://github.com/LazyVim/LazyVim/blob/main/CONTRIBUTING.md) guidelines. --- lua/lazyvim/plugins/extras/editor/fzf.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lua/lazyvim/plugins/extras/editor/fzf.lua b/lua/lazyvim/plugins/extras/editor/fzf.lua index 8a0a2927..f53ce57b 100644 --- a/lua/lazyvim/plugins/extras/editor/fzf.lua +++ b/lua/lazyvim/plugins/extras/editor/fzf.lua @@ -131,7 +131,11 @@ return { -- height is number of items minus 15 lines for the preview, with a max of 80% screen height height = math.floor(math.min(vim.o.lines * 0.8 - 16, #items + 2) + 0.5) + 16, width = 0.5, - preview = { + preview = not vim.tbl_isempty(LazyVim.lsp.get_clients({ bufnr = 0, name = "vtsls" })) and { + layout = "vertical", + vertical = "down:15,border-top", + hidden = "hidden", + } or { layout = "vertical", vertical = "down:15,border-top", }, From 351336244c0a68d4ebed7f687e27e6eab8e5da09 Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Mon, 24 Jun 2024 22:11:59 +0200 Subject: [PATCH 26/28] perf(markdown): add filetype in VeryLazy --- lua/lazyvim/plugins/extras/lang/markdown.lua | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/lua/lazyvim/plugins/extras/lang/markdown.lua b/lua/lazyvim/plugins/extras/lang/markdown.lua index 856d3ab6..c7f14cbd 100644 --- a/lua/lazyvim/plugins/extras/lang/markdown.lua +++ b/lua/lazyvim/plugins/extras/lang/markdown.lua @@ -1,6 +1,8 @@ -vim.filetype.add({ - extension = { mdx = "markdown.mdx" }, -}) +LazyVim.on_very_lazy(function() + vim.filetype.add({ + extension = { mdx = "markdown.mdx" }, + }) +end) return { recommended = function() return LazyVim.extras.wants({ From faee8ce5819c40852f574aafad55701e2492ffae Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Tue, 25 Jun 2024 00:24:38 +0200 Subject: [PATCH 27/28] fix(noice): dont show old messages when installing plugins --- lua/lazyvim/plugins/extras/util/octo.lua | 4 +--- lua/lazyvim/plugins/ui.lua | 9 +++++++++ 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/lua/lazyvim/plugins/extras/util/octo.lua b/lua/lazyvim/plugins/extras/util/octo.lua index cc5c47bf..a8286265 100644 --- a/lua/lazyvim/plugins/extras/util/octo.lua +++ b/lua/lazyvim/plugins/extras/util/octo.lua @@ -8,9 +8,6 @@ return { "pwntester/octo.nvim", cmd = "Octo", event = { { event = "BufReadCmd", pattern = "octo://*" } }, - init = function() - vim.treesitter.language.register("markdown", "octo") - end, opts = { enable_builtin = true, default_to_projects_v2 = true, @@ -41,6 +38,7 @@ return { { "pwntester/octo.nvim", opts = function(_, opts) + vim.treesitter.language.register("markdown", "octo") if LazyVim.has("telescope.nvim") then opts.picker = "telescope" elseif LazyVim.has("fzf-lua") then diff --git a/lua/lazyvim/plugins/ui.lua b/lua/lazyvim/plugins/ui.lua index 8adb760c..4586bf38 100644 --- a/lua/lazyvim/plugins/ui.lua +++ b/lua/lazyvim/plugins/ui.lua @@ -291,6 +291,15 @@ return { { "", function() if not require("noice.lsp").scroll(4) then return "" end end, silent = true, expr = true, desc = "Scroll Forward", mode = {"i", "n", "s"} }, { "", function() if not require("noice.lsp").scroll(-4) then return "" end end, silent = true, expr = true, desc = "Scroll Backward", mode = {"i", "n", "s"}}, }, + config = function(_, opts) + -- HACK: noice shows messages from before it was enabled, + -- but this is not ideal when Lazy is installing plugins, + -- so clear the messages in this case. + if vim.o.filetype == "lazy" then + vim.cmd([[messages clear]]) + end + require("noice").setup(opts) + end, }, -- icons From fa2fc6403185faabc47741b3aa2809192870b92e Mon Sep 17 00:00:00 2001 From: Folke Lemaitre Date: Tue, 25 Jun 2024 00:24:59 +0200 Subject: [PATCH 28/28] fix(dashboard): load dashboard when closing lazy if needed --- lua/lazyvim/plugins/ui.lua | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/lua/lazyvim/plugins/ui.lua b/lua/lazyvim/plugins/ui.lua index 4586bf38..a060cc65 100644 --- a/lua/lazyvim/plugins/ui.lua +++ b/lua/lazyvim/plugins/ui.lua @@ -357,13 +357,15 @@ return { button.key_format = " %s" end - -- close Lazy and re-open when the dashboard is ready + -- open dashboard after closing lazy if vim.o.filetype == "lazy" then - vim.cmd.close() - vim.api.nvim_create_autocmd("User", { - pattern = "DashboardLoaded", + vim.api.nvim_create_autocmd("WinClosed", { + pattern = tostring(vim.api.nvim_get_current_win()), + once = true, callback = function() - require("lazy").show() + vim.schedule(function() + vim.api.nvim_exec_autocmds("UIEnter", { group = "dashboard" }) + end) end, }) end