Add conditions to only load treesitter and neorg on NixOS systems

Remove magma_nvim
This commit is contained in:
Evie Litherland-Smith 2023-06-05 10:15:17 +01:00
parent a96d1016fd
commit 411da289ed
3 changed files with 3 additions and 19 deletions

View file

@ -1,5 +0,0 @@
return {
"dccsillag/magma-nvim",
cond = not vim.g.vscode,
event = { "FileType python" },
}

View file

@ -1,6 +1,6 @@
return {
"nvim-neorg/neorg",
cond = not vim.g.vscode,
cond = function() return string.match(vim.loop.os_uname().version, "NixOS") and not vim.g.vscode end,
build = ":Neorg sync-parsers",
event = { "FileType norg" },
cmd = "Neorg",

View file

@ -7,6 +7,7 @@ end
return {
"nvim-treesitter/nvim-treesitter",
cond = function() return string.match(vim.loop.os_uname().version, "NixOS") end,
version = false,
build = ":TSUpdate",
event = { "BufReadPre", "BufNewFile" },
@ -24,19 +25,7 @@ return {
require("nvim-treesitter.configs").setup(opts)
end,
opts = {
ensure_installed = {
"bash",
"fish",
"gitcommit",
"gitignore",
"lua",
"make",
"nix",
"python",
"vim",
"vimdoc",
},
auto_install = false,
auto_install = true,
highlight = {
enable = true,
disable = { "fortran" },