fix: Don't let extras overwrite treesitter config

This commit is contained in:
punkfairie 2025-03-02 09:59:13 -08:00
parent fe559c2214
commit 744b1ad145
Signed by: punkfairie
GPG key ID: B3C5488E9A1A7CA6

View file

@ -31,18 +31,6 @@ require('nixCatsUtils.lazyCat').setup(nixCats.pawsible { 'allPlugins', 'start',
{ 'williamboman/mason-lspconfig.nvim', enabled = require('nixCatsUtils').lazyAdd(true, false) },
{ 'williamboman/mason.nvim', enabled = require('nixCatsUtils').lazyAdd(true, false) },
{
'nvim-treesitter/nvim-treesitter',
build = require('nixCatsUtils').lazyAdd ':TSUpdate',
opts_extend = require('nixCatsUtils').lazyAdd(nil, false),
opts = {
-- nix already ensured they were installed, and we would need to change the parser_install_dir if we wanted to use it instead.
-- so we just disable install and do it via nix.
ensure_installed = require('nixCatsUtils').lazyAdd({ 'bash', 'c', 'diff', 'html', 'lua', 'luadoc', 'markdown', 'vim', 'vimdoc' }, false),
auto_install = require('nixCatsUtils').lazyAdd(true, false),
},
},
{
'folke/lazydev.nvim',
ft = 'lua',
@ -57,6 +45,19 @@ require('nixCatsUtils.lazyCat').setup(nixCats.pawsible { 'allPlugins', 'start',
-- extras
{ import = 'lazyvim.plugins.extras.lang.nix' },
-- this needs to be after extras to prevent extras from overwriting it
{
'nvim-treesitter/nvim-treesitter',
build = require('nixCatsUtils').lazyAdd ':TSUpdate',
opts_extend = require('nixCatsUtils').lazyAdd(nil, false),
opts = {
-- nix already ensured they were installed, and we would need to change the parser_install_dir if we wanted to use it instead.
-- so we just disable install and do it via nix.
ensure_installed = require('nixCatsUtils').lazyAdd({ 'bash', 'c', 'diff', 'html', 'lua', 'luadoc', 'markdown', 'vim', 'vimdoc' }, false),
auto_install = require('nixCatsUtils').lazyAdd(true, false),
},
},
-- import/override with your plugins
{ import = 'plugins' },
}, lazyOptions)