Compare commits
14 Commits
Author | SHA1 | Date | |
---|---|---|---|
5c4bd7150e | |||
0352f944c3 | |||
33557ae68b | |||
6dcf5d7159 | |||
5c5ae903c9 | |||
af9553135d | |||
704c29110d | |||
1db2af267e | |||
1c5a330b6b | |||
b8407f4b12 | |||
8235126a32 | |||
767d873f93 | |||
ffce089a9f | |||
7a1414b5e5 |
2
.github/.release-please-manifest.json
vendored
2
.github/.release-please-manifest.json
vendored
@ -1,3 +1,3 @@
|
||||
{
|
||||
".": "13.3.1"
|
||||
".": "13.4.0"
|
||||
}
|
||||
|
16
CHANGELOG.md
16
CHANGELOG.md
@ -1,5 +1,21 @@
|
||||
# Changelog
|
||||
|
||||
## [13.4.0](https://github.com/LazyVim/LazyVim/compare/v13.3.1...v13.4.0) (2024-11-16)
|
||||
|
||||
|
||||
### Features
|
||||
|
||||
* **blink:** auto-enable catppuccin integration ([#4799](https://github.com/LazyVim/LazyVim/issues/4799)) ([ffce089](https://github.com/LazyVim/LazyVim/commit/ffce089a9f1268ff73c7de7c4f45e1a366dc4d34))
|
||||
* **copilot-chat:** remove deprecated options ([#4802](https://github.com/LazyVim/LazyVim/issues/4802)) ([7a1414b](https://github.com/LazyVim/LazyVim/commit/7a1414b5e5950bde34b9bdc0dbc3dd20109f2ac9))
|
||||
* **dial:** support vue filetype ([#4785](https://github.com/LazyVim/LazyVim/issues/4785)) ([8235126](https://github.com/LazyVim/LazyVim/commit/8235126a321eaae093f319398ffec5949f1ab8be))
|
||||
* **extras:** add biome formatter ([#4448](https://github.com/LazyVim/LazyVim/issues/4448)) ([b8407f4](https://github.com/LazyVim/LazyVim/commit/b8407f4b128891c3bdf35a2c403ba23d1e01f3ff))
|
||||
* **vscode:** automatically enable the vscode extra when running in vscode ([1c5a330](https://github.com/LazyVim/LazyVim/commit/1c5a330b6be8007088d84361fee5d2b08771598c))
|
||||
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* **terminal:** set shellcmdflags for powershell to recommended values. Closes [#4805](https://github.com/LazyVim/LazyVim/issues/4805) ([1db2af2](https://github.com/LazyVim/LazyVim/commit/1db2af267eeb9046550ac29bd543f3b3021cdd7b))
|
||||
|
||||
## [13.3.1](https://github.com/LazyVim/LazyVim/compare/v13.3.0...v13.3.1) (2024-11-15)
|
||||
|
||||
|
||||
|
7
NEWS.md
7
NEWS.md
@ -2,6 +2,13 @@
|
||||
|
||||
## 13.x
|
||||
|
||||
- **LazyVim** now uses `Snacks.dashboard` as the default dashboard.
|
||||
Check the [docs](https://github.com/folke/snacks.nvim/blob/main/docs/dashboard.md),
|
||||
for more information and examples.
|
||||
|
||||
- A new [dashboard-nvim](https://github.com/nvimdev/dashboard-nvim) extra
|
||||
is available for those who prefer the old dashboard.
|
||||
|
||||
- Big new release with a lot of changes and improvements!
|
||||
|
||||
- The biggest change is the move of a bunch of core features to
|
||||
|
@ -1,4 +1,4 @@
|
||||
*LazyVim.txt* For Neovim Last change: 2024 November 15
|
||||
*LazyVim.txt* For Neovim Last change: 2024 November 18
|
||||
|
||||
==============================================================================
|
||||
Table of Contents *LazyVim-table-of-contents*
|
||||
|
@ -3,7 +3,7 @@ _G.LazyVim = require("lazyvim.util")
|
||||
---@class LazyVimConfig: LazyVimOptions
|
||||
local M = {}
|
||||
|
||||
M.version = "13.3.1" -- x-release-please-version
|
||||
M.version = "13.4.0" -- x-release-please-version
|
||||
LazyVim.config = M
|
||||
|
||||
---@class LazyVimOptions
|
||||
|
@ -24,16 +24,11 @@ return {
|
||||
user = user:sub(1, 1):upper() .. user:sub(2)
|
||||
return {
|
||||
auto_insert_mode = true,
|
||||
show_help = true,
|
||||
question_header = " " .. user .. " ",
|
||||
answer_header = " Copilot ",
|
||||
window = {
|
||||
width = 0.4,
|
||||
},
|
||||
selection = function(source)
|
||||
local select = require("CopilotChat.select")
|
||||
return select.visual(source) or select.buffer(source)
|
||||
end,
|
||||
}
|
||||
end,
|
||||
keys = {
|
||||
@ -66,16 +61,11 @@ return {
|
||||
desc = "Quick Chat (CopilotChat)",
|
||||
mode = { "n", "v" },
|
||||
},
|
||||
-- Show help actions with telescope
|
||||
{ "<leader>ad", M.pick("help"), desc = "Diagnostic Help (CopilotChat)", mode = { "n", "v" } },
|
||||
-- Show prompts actions with telescope
|
||||
{ "<leader>ap", M.pick("prompt"), desc = "Prompt Actions (CopilotChat)", mode = { "n", "v" } },
|
||||
},
|
||||
config = function(_, opts)
|
||||
local chat = require("CopilotChat")
|
||||
if pcall(require, "cmp") then
|
||||
require("CopilotChat.integrations.cmp").setup()
|
||||
end
|
||||
|
||||
vim.api.nvim_create_autocmd("BufEnter", {
|
||||
pattern = "copilot-chat",
|
||||
|
@ -8,7 +8,6 @@ return {
|
||||
"tzachar/cmp-tabnine",
|
||||
build = {
|
||||
LazyVim.is_win() and "pwsh -noni .\\install.ps1" or "./install.sh",
|
||||
":CmpTabnineHub",
|
||||
},
|
||||
dependencies = "hrsh7th/nvim-cmp",
|
||||
opts = {
|
||||
|
@ -121,4 +121,12 @@ return {
|
||||
},
|
||||
},
|
||||
},
|
||||
-- catppuccin support
|
||||
{
|
||||
"catppuccin",
|
||||
optional = true,
|
||||
opts = {
|
||||
integrations = { blink_cmp = true },
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -98,7 +98,10 @@ return {
|
||||
return {
|
||||
dials_by_ft = {
|
||||
css = "css",
|
||||
vue = "vue",
|
||||
javascript = "typescript",
|
||||
typescript = "typescript",
|
||||
typescriptreact = "typescript",
|
||||
javascriptreact = "typescript",
|
||||
json = "json",
|
||||
lua = "lua",
|
||||
@ -106,8 +109,6 @@ return {
|
||||
python = "python",
|
||||
sass = "css",
|
||||
scss = "css",
|
||||
typescript = "typescript",
|
||||
typescriptreact = "typescript",
|
||||
yaml = "yaml",
|
||||
},
|
||||
groups = {
|
||||
@ -122,6 +123,14 @@ return {
|
||||
augend.constant.alias.bool, -- boolean value (true <-> false)
|
||||
logical_alias,
|
||||
},
|
||||
vue = {
|
||||
augend.integer.alias.decimal_int, -- nonnegative and negative decimal number
|
||||
augend.constant.alias.bool, -- boolean value (true <-> false)
|
||||
logical_alias,
|
||||
augend.constant.new({ elements = { "let", "const" } }),
|
||||
augend.hexcolor.new({ case = "lower" }),
|
||||
augend.hexcolor.new({ case = "upper" }),
|
||||
},
|
||||
typescript = {
|
||||
augend.integer.alias.decimal_int, -- nonnegative and negative decimal number
|
||||
augend.constant.alias.bool, -- boolean value (true <-> false)
|
||||
|
59
lua/lazyvim/plugins/extras/formatting/biome.lua
Normal file
59
lua/lazyvim/plugins/extras/formatting/biome.lua
Normal file
@ -0,0 +1,59 @@
|
||||
---@diagnostic disable: inject-field
|
||||
if lazyvim_docs then
|
||||
-- Enable this option to avoid conflicts with Prettier.
|
||||
vim.g.lazyvim_prettier_needs_config = true
|
||||
end
|
||||
|
||||
-- https://biomejs.dev/internals/language-support/
|
||||
local supported = {
|
||||
"astro",
|
||||
"css",
|
||||
"graphql",
|
||||
-- "html",
|
||||
"javascript",
|
||||
"javascriptreact",
|
||||
"json",
|
||||
"jsonc",
|
||||
-- "markdown",
|
||||
"svelte",
|
||||
"typescript",
|
||||
"typescriptreact",
|
||||
"vue",
|
||||
-- "yaml",
|
||||
}
|
||||
|
||||
return {
|
||||
{
|
||||
"williamboman/mason.nvim",
|
||||
opts = { ensure_installed = { "biome" } },
|
||||
},
|
||||
|
||||
{
|
||||
"stevearc/conform.nvim",
|
||||
optional = true,
|
||||
---@param opts ConformOpts
|
||||
opts = function(_, opts)
|
||||
opts.formatters_by_ft = opts.formatters_by_ft or {}
|
||||
for _, ft in ipairs(supported) do
|
||||
opts.formatters_by_ft[ft] = opts.formatters_by_ft[ft] or {}
|
||||
table.insert(opts.formatters_by_ft[ft], "biome")
|
||||
end
|
||||
|
||||
opts.formatters = opts.formatters or {}
|
||||
opts.formatters.biome = {
|
||||
require_cwd = true,
|
||||
}
|
||||
end,
|
||||
},
|
||||
|
||||
-- none-ls support
|
||||
{
|
||||
"nvimtools/none-ls.nvim",
|
||||
optional = true,
|
||||
opts = function(_, opts)
|
||||
local nls = require("null-ls")
|
||||
opts.sources = opts.sources or {}
|
||||
table.insert(opts.sources, nls.builtins.formatting.biome)
|
||||
end,
|
||||
},
|
||||
}
|
@ -1,7 +1,6 @@
|
||||
return {
|
||||
|
||||
{ "nvimdev/dashboard-nvim", enabled = false },
|
||||
{ "echasnovski/mini.starter", enabled = false },
|
||||
{ "folke/snacks.nvim", opts = { dashboard = { enabled = false } } },
|
||||
-- Dashboard. This runs when neovim starts, and is what displays
|
||||
-- the "LAZYVIM" banner.
|
||||
{
|
||||
|
68
lua/lazyvim/plugins/extras/ui/dashboard-nvim.lua
Normal file
68
lua/lazyvim/plugins/extras/ui/dashboard-nvim.lua
Normal file
@ -0,0 +1,68 @@
|
||||
return {
|
||||
{ "folke/snacks.nvim", opts = { dashboard = { enabled = false } } },
|
||||
{
|
||||
"nvimdev/dashboard-nvim",
|
||||
lazy = false, -- As https://github.com/nvimdev/dashboard-nvim/pull/450, dashboard-nvim shouldn't be lazy-loaded to properly handle stdin.
|
||||
opts = function()
|
||||
local logo = [[
|
||||
██╗ █████╗ ███████╗██╗ ██╗██╗ ██╗██╗███╗ ███╗ Z
|
||||
██║ ██╔══██╗╚══███╔╝╚██╗ ██╔╝██║ ██║██║████╗ ████║ Z
|
||||
██║ ███████║ ███╔╝ ╚████╔╝ ██║ ██║██║██╔████╔██║ z
|
||||
██║ ██╔══██║ ███╔╝ ╚██╔╝ ╚██╗ ██╔╝██║██║╚██╔╝██║ z
|
||||
███████╗██║ ██║███████╗ ██║ ╚████╔╝ ██║██║ ╚═╝ ██║
|
||||
╚══════╝╚═╝ ╚═╝╚══════╝ ╚═╝ ╚═══╝ ╚═╝╚═╝ ╚═╝
|
||||
]]
|
||||
|
||||
logo = string.rep("\n", 8) .. logo .. "\n\n"
|
||||
|
||||
local opts = {
|
||||
theme = "doom",
|
||||
hide = {
|
||||
-- this is taken care of by lualine
|
||||
-- enabling this messes up the actual laststatus setting after loading a file
|
||||
statusline = false,
|
||||
},
|
||||
config = {
|
||||
header = vim.split(logo, "\n"),
|
||||
-- stylua: ignore
|
||||
center = {
|
||||
{ action = 'lua LazyVim.pick()()', desc = " Find File", icon = " ", key = "f" },
|
||||
{ action = "ene | startinsert", desc = " New File", icon = " ", key = "n" },
|
||||
{ action = 'lua LazyVim.pick("oldfiles")()', desc = " Recent Files", icon = " ", key = "r" },
|
||||
{ action = 'lua LazyVim.pick("live_grep")()', desc = " Find Text", icon = " ", key = "g" },
|
||||
{ action = 'lua LazyVim.pick.config_files()()', desc = " Config", icon = " ", key = "c" },
|
||||
{ action = 'lua require("persistence").load()', desc = " Restore Session", icon = " ", key = "s" },
|
||||
{ action = "LazyExtras", desc = " Lazy Extras", icon = " ", key = "x" },
|
||||
{ action = "Lazy", desc = " Lazy", icon = " ", key = "l" },
|
||||
{ action = function() vim.api.nvim_input("<cmd>qa<cr>") end, desc = " Quit", icon = " ", key = "q" },
|
||||
},
|
||||
footer = function()
|
||||
local stats = require("lazy").stats()
|
||||
local ms = (math.floor(stats.startuptime * 100 + 0.5) / 100)
|
||||
return { "⚡ Neovim loaded " .. stats.loaded .. "/" .. stats.count .. " plugins in " .. ms .. "ms" }
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
for _, button in ipairs(opts.config.center) do
|
||||
button.desc = button.desc .. string.rep(" ", 43 - #button.desc)
|
||||
button.key_format = " %s"
|
||||
end
|
||||
|
||||
-- open dashboard after closing lazy
|
||||
if vim.o.filetype == "lazy" then
|
||||
vim.api.nvim_create_autocmd("WinClosed", {
|
||||
pattern = tostring(vim.api.nvim_get_current_win()),
|
||||
once = true,
|
||||
callback = function()
|
||||
vim.schedule(function()
|
||||
vim.api.nvim_exec_autocmds("UIEnter", { group = "dashboard" })
|
||||
end)
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
return opts
|
||||
end,
|
||||
},
|
||||
}
|
@ -1,8 +1,7 @@
|
||||
-- start screen
|
||||
return {
|
||||
-- disable alpha
|
||||
{ "goolord/alpha-nvim", enabled = false },
|
||||
{ "nvimdev/dashboard-nvim", enabled = false },
|
||||
{ "folke/snacks.nvim", opts = { dashboard = { enabled = false } } },
|
||||
|
||||
-- enable mini.starter
|
||||
{
|
||||
|
@ -30,11 +30,9 @@ return {
|
||||
opts = function()
|
||||
---@type snacks.Config
|
||||
return {
|
||||
bigfile = { enabled = true },
|
||||
notifier = { enabled = true },
|
||||
quickfile = { enabled = true },
|
||||
bigfile = { enabled = true },
|
||||
words = { enabled = true },
|
||||
toggle = { map = LazyVim.safe_keymap_set },
|
||||
statuscolumn = { enabled = false }, -- we set this in options.lua
|
||||
terminal = {
|
||||
win = {
|
||||
@ -46,6 +44,8 @@ return {
|
||||
},
|
||||
},
|
||||
},
|
||||
toggle = { map = LazyVim.safe_keymap_set },
|
||||
words = { enabled = true },
|
||||
}
|
||||
end,
|
||||
keys = {
|
||||
|
@ -84,7 +84,7 @@ return {
|
||||
options = {
|
||||
theme = "auto",
|
||||
globalstatus = vim.o.laststatus == 3,
|
||||
disabled_filetypes = { statusline = { "dashboard", "alpha", "ministarter" } },
|
||||
disabled_filetypes = { statusline = { "dashboard", "alpha", "ministarter", "snacks_dashboard" } },
|
||||
},
|
||||
sections = {
|
||||
lualine_a = { "mode" },
|
||||
@ -307,68 +307,31 @@ return {
|
||||
{ "MunifTanjim/nui.nvim", lazy = true },
|
||||
|
||||
{
|
||||
"nvimdev/dashboard-nvim",
|
||||
lazy = false, -- As https://github.com/nvimdev/dashboard-nvim/pull/450, dashboard-nvim shouldn't be lazy-loaded to properly handle stdin.
|
||||
opts = function()
|
||||
local logo = [[
|
||||
██╗ █████╗ ███████╗██╗ ██╗██╗ ██╗██╗███╗ ███╗ Z
|
||||
██║ ██╔══██╗╚══███╔╝╚██╗ ██╔╝██║ ██║██║████╗ ████║ Z
|
||||
██║ ███████║ ███╔╝ ╚████╔╝ ██║ ██║██║██╔████╔██║ z
|
||||
██║ ██╔══██║ ███╔╝ ╚██╔╝ ╚██╗ ██╔╝██║██║╚██╔╝██║ z
|
||||
███████╗██║ ██║███████╗ ██║ ╚████╔╝ ██║██║ ╚═╝ ██║
|
||||
╚══════╝╚═╝ ╚═╝╚══════╝ ╚═╝ ╚═══╝ ╚═╝╚═╝ ╚═╝
|
||||
]]
|
||||
|
||||
logo = string.rep("\n", 8) .. logo .. "\n\n"
|
||||
|
||||
local opts = {
|
||||
theme = "doom",
|
||||
hide = {
|
||||
-- this is taken care of by lualine
|
||||
-- enabling this messes up the actual laststatus setting after loading a file
|
||||
statusline = false,
|
||||
},
|
||||
config = {
|
||||
header = vim.split(logo, "\n"),
|
||||
-- stylua: ignore
|
||||
center = {
|
||||
{ action = 'lua LazyVim.pick()()', desc = " Find File", icon = " ", key = "f" },
|
||||
{ action = "ene | startinsert", desc = " New File", icon = " ", key = "n" },
|
||||
{ action = 'lua LazyVim.pick("oldfiles")()', desc = " Recent Files", icon = " ", key = "r" },
|
||||
{ action = 'lua LazyVim.pick("live_grep")()', desc = " Find Text", icon = " ", key = "g" },
|
||||
{ action = 'lua LazyVim.pick.config_files()()', desc = " Config", icon = " ", key = "c" },
|
||||
{ action = 'lua require("persistence").load()', desc = " Restore Session", icon = " ", key = "s" },
|
||||
{ action = "LazyExtras", desc = " Lazy Extras", icon = " ", key = "x" },
|
||||
{ action = "Lazy", desc = " Lazy", icon = " ", key = "l" },
|
||||
{ action = function() vim.api.nvim_input("<cmd>qa<cr>") end, desc = " Quit", icon = " ", key = "q" },
|
||||
},
|
||||
footer = function()
|
||||
local stats = require("lazy").stats()
|
||||
local ms = (math.floor(stats.startuptime * 100 + 0.5) / 100)
|
||||
return { "⚡ Neovim loaded " .. stats.loaded .. "/" .. stats.count .. " plugins in " .. ms .. "ms" }
|
||||
"folke/snacks.nvim",
|
||||
opts = {
|
||||
dashboard = {
|
||||
preset = {
|
||||
header = [[
|
||||
██╗ █████╗ ███████╗██╗ ██╗██╗ ██╗██╗███╗ ███╗ Z
|
||||
██║ ██╔══██╗╚══███╔╝╚██╗ ██╔╝██║ ██║██║████╗ ████║ Z
|
||||
██║ ███████║ ███╔╝ ╚████╔╝ ██║ ██║██║██╔████╔██║ z
|
||||
██║ ██╔══██║ ███╔╝ ╚██╔╝ ╚██╗ ██╔╝██║██║╚██╔╝██║ z
|
||||
███████╗██║ ██║███████╗ ██║ ╚████╔╝ ██║██║ ╚═╝ ██║
|
||||
╚══════╝╚═╝ ╚═╝╚══════╝ ╚═╝ ╚═══╝ ╚═╝╚═╝ ╚═╝
|
||||
]],
|
||||
---@param keys snacks.dashboard.Item[]
|
||||
keys = function(keys)
|
||||
-- add LazyExtra before Lazy
|
||||
for k, key in ipairs(keys) do
|
||||
if key.action == ":Lazy" then
|
||||
key.key = "l" -- we don't have multiple panes, so `l` is free
|
||||
table.insert(keys, k, { icon = " ", desc = "Lazy Extras", action = ":LazyExtras", key = "x" })
|
||||
break
|
||||
end
|
||||
end
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
for _, button in ipairs(opts.config.center) do
|
||||
button.desc = button.desc .. string.rep(" ", 43 - #button.desc)
|
||||
button.key_format = " %s"
|
||||
end
|
||||
|
||||
-- open dashboard after closing lazy
|
||||
if vim.o.filetype == "lazy" then
|
||||
vim.api.nvim_create_autocmd("WinClosed", {
|
||||
pattern = tostring(vim.api.nvim_get_current_win()),
|
||||
once = true,
|
||||
callback = function()
|
||||
vim.schedule(function()
|
||||
vim.api.nvim_exec_autocmds("UIEnter", { group = "dashboard" })
|
||||
end)
|
||||
end,
|
||||
})
|
||||
end
|
||||
|
||||
return opts
|
||||
end,
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
@ -27,6 +27,9 @@ LazyVim.plugin.save_core()
|
||||
if vim.tbl_contains(compat, v) then
|
||||
table.insert(extras, 1, "lazyvim.plugins.compat.nvim-" .. v)
|
||||
end
|
||||
if vim.g.vscode then
|
||||
table.insert(extras, 1, "lazyvim.plugins.extras.vscode")
|
||||
end
|
||||
|
||||
table.sort(extras, function(a, b)
|
||||
local pa = prios[a] or 50
|
||||
|
@ -18,13 +18,13 @@ function M.setup(shell)
|
||||
|
||||
-- Setting shell command flags
|
||||
vim.o.shellcmdflag =
|
||||
"-NoLogo -ExecutionPolicy RemoteSigned -Command [Console]::InputEncoding=[Console]::OutputEncoding=[System.Text.UTF8Encoding]::new();$PSDefaultParameterValues['Out-File:Encoding']='utf8';"
|
||||
"-NoLogo -NonInteractive -ExecutionPolicy RemoteSigned -Command [Console]::InputEncoding=[Console]::OutputEncoding=[System.Text.UTF8Encoding]::new();$PSDefaultParameterValues['Out-File:Encoding']='utf8';$PSStyle.OutputRendering='plaintext';Remove-Alias -Force -ErrorAction SilentlyContinue tee;"
|
||||
|
||||
-- Setting shell redirection
|
||||
vim.o.shellredir = '2>&1 | %%{ "$_" } | Out-File %s; exit $LastExitCode'
|
||||
|
||||
-- Setting shell pipe
|
||||
vim.o.shellpipe = '2>&1 | %%{ "$_" } | Tee-Object %s; exit $LastExitCode'
|
||||
vim.o.shellpipe = '2>&1 | %%{ "$_" } | tee %s; exit $LastExitCode'
|
||||
|
||||
-- Setting shell quote options
|
||||
vim.o.shellquote = ""
|
||||
|
@ -15,7 +15,11 @@ function M.foldexpr()
|
||||
if vim.bo[buf].filetype == "" then
|
||||
return "0"
|
||||
end
|
||||
vim.b[buf].ts_folds = pcall(vim.treesitter.get_parser, buf)
|
||||
if vim.bo[buf].filetype:find("dashboard") then
|
||||
vim.b[buf].ts_folds = false
|
||||
else
|
||||
vim.b[buf].ts_folds = pcall(vim.treesitter.get_parser, buf)
|
||||
end
|
||||
end
|
||||
return vim.b[buf].ts_folds and vim.treesitter.foldexpr() or "0"
|
||||
end
|
||||
|
Reference in New Issue
Block a user