Compare commits

..

4 Commits

5 changed files with 82 additions and 3 deletions
CHANGELOG.md
lua/lazyvim
config
plugins

@ -1,5 +1,18 @@
# Changelog
## [9.6.0](https://github.com/LazyVim/LazyVim/compare/v9.5.0...v9.6.0) (2023-10-08)
### Features
* **extra:** add extra `util.dot` that configures multiple ft and treesitter langs when needed ([639a6e7](https://github.com/LazyVim/LazyVim/commit/639a6e7545830602c09711b3757a28537baf8e75))
### Bug Fixes
* **config:** trigger LazyFile additionally on BufWritePre for saving unnamed files ([e11a3cb](https://github.com/LazyVim/LazyVim/commit/e11a3cbe800a1216062f7cefd25827f6fdad9daa))
* **yaml:** yaml schemas are a dict, not a list, so merge properly. Fixes [#1636](https://github.com/LazyVim/LazyVim/issues/1636) ([33c677a](https://github.com/LazyVim/LazyVim/commit/33c677a55e97ee115ad7050856856df7cd96b3e1))
## [9.5.0](https://github.com/LazyVim/LazyVim/compare/v9.4.1...v9.5.0) (2023-10-08)

@ -3,7 +3,7 @@ local M = {}
M.lazy_version = ">=10.8.0"
M.use_lazy_file = true
M.lazy_file_events = { "BufReadPost", "BufNewFile" }
M.lazy_file_events = { "BufReadPost", "BufNewFile", "BufWritePre" }
---@class LazyVimOptions
local defaults = {

@ -35,8 +35,11 @@ return {
},
-- lazy-load schemastore when needed
on_new_config = function(new_config)
new_config.settings.yaml.schemas = new_config.settings.yaml.schemas or {}
vim.list_extend(new_config.settings.yaml.schemas, require("schemastore").yaml.schemas())
new_config.settings.yaml.schemas = vim.tbl_deep_extend(
"force",
new_config.settings.yaml.schemas or {},
require("schemastore").yaml.schemas()
)
end,
settings = {
redhat = { telemetry = { enabled = false } },

@ -0,0 +1,62 @@
---@type string
local xdg_config = vim.env.XDG_CONFIG_HOME or vim.env.HOME .. "/.config"
---@param path string
local function have(path)
return vim.loop.fs_stat(xdg_config .. "/" .. path) ~= nil
end
return {
-- Add Hyprland Parser
{
"luckasRanarison/tree-sitter-hypr",
enabled = have("hypr"),
event = "BufRead */hypr/*.conf",
config = function()
-- Fix ft detection for hyprland
vim.filetype.add({
pattern = { [".*/hypr/.*%.conf"] = "hypr" },
})
require("nvim-treesitter.parsers").get_parser_configs().hypr = {
install_info = {
url = "https://github.com/luckasRanarison/tree-sitter-hypr",
files = { "src/parser.c" },
branch = "master",
},
filetype = "hypr",
}
end,
},
-- add some stuff to treesitter
{
"nvim-treesitter/nvim-treesitter",
opts = function(_, opts)
local function add(lang)
if type(opts.ensure_installed) ~= "table" then
table.insert(opts.ensure_installed, lang)
end
end
vim.filetype.add({
extension = { rasi = "rasi" },
pattern = {
[".*/waybar/config"] = "jsonc",
[".*/mako/config"] = "dosini",
[".*/kitty/*.conf"] = "bash",
},
})
add("git_config")
if have("fish") then
add("fish")
end
if have("rofi") or have("wofi") then
add("rasi")
end
end,
},
}

@ -40,6 +40,7 @@ return {
{ "<bs>", desc = "Decrement selection", mode = "x" },
},
---@type TSConfig
---@diagnostic disable-next-line: missing-fields
opts = {
highlight = { enable = true },
indent = { enable = true },