diff --git a/flake.lock b/flake.lock index dfd49c4..8555657 100644 --- a/flake.lock +++ b/flake.lock @@ -20,11 +20,11 @@ ] }, "locked": { - "lastModified": 1739103745, - "narHash": "sha256-c53dcRaw0F4Os9WD05HwIRs9kTDZw4Mxe1XK4edEALo=", + "lastModified": 1738183445, + "narHash": "sha256-C1He3N1SA8D2u+TSlldbA9wiYwDvXI4GxX3zKaeD7qU=", "owner": "hyprwm", "repo": "aquamarine", - "rev": "a3dda0d10ce9aa1d1dfb7a6c139ea8c2872c74bd", + "rev": "48a000cf35dd10bfeb231152735aebbe875f4b74", "type": "github" }, "original": { @@ -69,6 +69,22 @@ "type": "github" } }, + "flake-compat_2": { + "flake": false, + "locked": { + "lastModified": 1733328505, + "narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=", + "owner": "edolstra", + "repo": "flake-compat", + "rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec", + "type": "github" + }, + "original": { + "owner": "edolstra", + "repo": "flake-compat", + "type": "github" + } + }, "gitignore": { "inputs": { "nixpkgs": [ @@ -98,11 +114,11 @@ ] }, "locked": { - "lastModified": 1739314552, - "narHash": "sha256-ggVf2BclyIW3jexc/uvgsgJH4e2cuG6Nyg54NeXgbFI=", + "lastModified": 1738200030, + "narHash": "sha256-z2DVxun8fEH0yeVIyfL68hXht+k2h3vEwNVxJPOMCgU=", "owner": "nix-community", "repo": "home-manager", - "rev": "83bd3a26ac0526ae04fa74df46738bb44b89dcdd", + "rev": "86a0d627cae02e8cc5d29eeb03de97f8c652a4bb", "type": "github" }, "original": { @@ -147,11 +163,11 @@ ] }, "locked": { - "lastModified": 1738664950, - "narHash": "sha256-xIeGNM+iivwVHkv9tHwOqoUP5dDrtees34bbFKKMZYs=", + "lastModified": 1738178255, + "narHash": "sha256-+D6Nu2ewXbMTFzx/Q4jDOo+LAOUPr0cxQJg5k33daIE=", "owner": "hyprwm", "repo": "hyprcursor", - "rev": "7c6d165e1eb9045a996551eb9f121b6d1b30adc3", + "rev": "dcadd3398abe146d60c67e0d9ee6e27b301cae82", "type": "github" }, "original": { @@ -176,11 +192,11 @@ ] }, "locked": { - "lastModified": 1739049071, - "narHash": "sha256-3+7TpXMrbsUXSwgr5VAKAnmkzMb6JO+Rvc9XRb5NMg4=", + "lastModified": 1738018829, + "narHash": "sha256-5Ol5iahMlELx3lWuChyZsqqLk6sP6aqaJCJFw92OZGo=", "owner": "hyprwm", "repo": "hyprgraphics", - "rev": "175c6b29b6ff82100539e7c4363a35a02c74dd73", + "rev": "12cd7034e441a5ebfdef1a090c0788413b4a635b", "type": "github" }, "original": { @@ -205,11 +221,11 @@ "xdph": "xdph" }, "locked": { - "lastModified": 1739285923, - "narHash": "sha256-2G2qqyx9MIlWTxNVm+ADZvZSwrNhrV6UtazonxZ9FJ0=", + "lastModified": 1738192585, + "narHash": "sha256-bhlT5u8SHc10eFA695klLlKOm3Wb6um1bxuSgp3D5TU=", "owner": "hyprwm", "repo": "Hyprland", - "rev": "f83fe9986b34c53c67b113a015d54fe8c084e9bd", + "rev": "d462cc7fa166e1e6a6f14b58a2dd1e8b92e15426", "type": "github" }, "original": { @@ -230,11 +246,11 @@ ] }, "locked": { - "lastModified": 1738422629, - "narHash": "sha256-5v+bv75wJWvahyM2xcMTSNNxmV8a7hb01Eey5zYnBJw=", + "lastModified": 1737556638, + "narHash": "sha256-laKgI3mr2qz6tas/q3tuGPxMdsGhBi/w+HO+hO2f1AY=", "owner": "hyprwm", "repo": "hyprland-protocols", - "rev": "755aef8dab49d0fc4663c715fa4ad221b2aedaed", + "rev": "4c75dd5c015c8a0e5a34c6d02a018a650f57feb5", "type": "github" }, "original": { @@ -298,11 +314,11 @@ ] }, "locked": { - "lastModified": 1739048983, - "narHash": "sha256-REhTcXq4qs3B3cCDtLlYDz0GZvmsBSh947Ub6pQWGTQ=", + "lastModified": 1737981711, + "narHash": "sha256-lh6cL5D8nPplB3WovCQjLUZ7k7MViiBrMlpkfm4R7/c=", "owner": "hyprwm", "repo": "hyprland-qtutils", - "rev": "3504a293c8f8db4127cb0f7cfc1a318ffb4316f8", + "rev": "96bf0677fa9cd13508294e3d4559dfbbc8beff73", "type": "github" }, "original": { @@ -327,11 +343,11 @@ ] }, "locked": { - "lastModified": 1739048914, - "narHash": "sha256-vd5rJBTmp2w7SDgfv23Zcd84ktI5eDA7e5UBzx+pKrU=", + "lastModified": 1737634606, + "narHash": "sha256-W7W87Cv6wqZ9PHegI6rH1+ve3zJPiyevMFf0/HwdbCQ=", "owner": "hyprwm", "repo": "hyprlang", - "rev": "a7334904d591f38757c46fbe2ab68651877d9099", + "rev": "f41271d35cc0f370d300413d756c2677f386af9d", "type": "github" }, "original": { @@ -352,11 +368,11 @@ ] }, "locked": { - "lastModified": 1739048933, - "narHash": "sha256-ck6MaoYvISBQKqZR+HcxXnx0wOhyCauxfVMaV5zhJxQ=", + "lastModified": 1737978343, + "narHash": "sha256-TfFS0HCEJh63Kahrkp1h9hVDMdLU8a37Zz+IFucxyfA=", "owner": "hyprwm", "repo": "hyprutils", - "rev": "e4e018a2ca6f5a9c33511973454199e1c7c85499", + "rev": "6a8bc9d2a4451df12f5179dc0b1d2d46518a90ab", "type": "github" }, "original": { @@ -377,11 +393,11 @@ ] }, "locked": { - "lastModified": 1739049028, - "narHash": "sha256-RleJp7LYbr6s+M1xgbmhtBs+fYa3ZdIiF7+QalJ4D1g=", + "lastModified": 1735493474, + "narHash": "sha256-fktzv4NaqKm94VAkAoVqO/nqQlw+X0/tJJNAeCSfzK4=", "owner": "hyprwm", "repo": "hyprwayland-scanner", - "rev": "04146df74a8d5ec0b579657307be01f1e241125f", + "rev": "de913476b59ee88685fdc018e77b8f6637a2ae0b", "type": "github" }, "original": { @@ -439,11 +455,11 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1739020877, - "narHash": "sha256-mIvECo/NNdJJ/bXjNqIh8yeoSjVLAuDuTUzAo7dzs8Y=", + "lastModified": 1737885589, + "narHash": "sha256-Zf0hSrtzaM1DEz8//+Xs51k/wdSajticVrATqDrfQjg=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "a79cfe0ebd24952b580b1cf08cd906354996d547", + "rev": "852ff1d9e153d8875a83602e03fdef8a63f0ecf8", "type": "github" }, "original": { @@ -455,11 +471,11 @@ }, "nixpkgs_4": { "locked": { - "lastModified": 1739214665, - "narHash": "sha256-26L8VAu3/1YRxS8MHgBOyOM8xALdo6N0I04PgorE7UM=", + "lastModified": 1738142207, + "narHash": "sha256-NGqpVVxNAHwIicXpgaVqJEJWeyqzoQJ9oc8lnK9+WC4=", "owner": "nixos", "repo": "nixpkgs", - "rev": "64e75cd44acf21c7933d61d7721e812eac1b5a0a", + "rev": "9d3ae807ebd2981d593cddd0080856873139aa40", "type": "github" }, "original": { @@ -504,17 +520,18 @@ }, "spicetify-nix": { "inputs": { + "flake-compat": "flake-compat_2", "nixpkgs": [ "nixpkgs" ], "systems": "systems_3" }, "locked": { - "lastModified": 1739223162, - "narHash": "sha256-YrbYTM0CkZQG38Ysr2gF4BYdsQDNQtQ4YdQTDgw/zWM=", + "lastModified": 1738099675, + "narHash": "sha256-q1oixDeEvoKm8t7Fr6vEGnv4sb8vRXCa6rF6YWIbGmk=", "owner": "Gerg-L", "repo": "spicetify-nix", - "rev": "dea717737d04a2a3e877c082bfd2c7f91c1a33ff", + "rev": "2f0cc0c110c25804cd2f6c167ab66f567941452c", "type": "github" }, "original": { diff --git a/modules/home-manager/packages.nix b/modules/home-manager/packages.nix index 553a846..41afbc0 100644 --- a/modules/home-manager/packages.nix +++ b/modules/home-manager/packages.nix @@ -37,7 +37,7 @@ libreoffice # Creative work - # aseprite FIXME: Broken currently + aseprite blender krita lmms diff --git a/modules/home-manager/programs/fish/default.nix b/modules/home-manager/programs/fish/default.nix index da4f342..3c5e4d1 100644 --- a/modules/home-manager/programs/fish/default.nix +++ b/modules/home-manager/programs/fish/default.nix @@ -17,31 +17,25 @@ ## Add directories to $PATH fish_add_path /home/wizardlink/.local/share/scripts \ /home/wizardlink/.config/emacs/bin \ + /home/wizardlink/.spicetify \ /home/wizardlink/.nimble/bin \ /home/wizardlink/.cargo/bin \ /home/wizardlink/.local/bin \ - /lib/flatpak/exports/bin + /lib/flatpak/exports/bin \ + /home/wizardlink/.local/share/scripts/burrito \ + ${pkgs.vscode-extensions.vadimcn.vscode-lldb.adapter}/bin zoxide init --cmd cd fish | source ''; shellAbbrs = { z = "zoxide"; - pkg_expr = { - position = "anywhere"; - expansion = "--expr 'with import { % }; '"; - }; - impure_cmd = { - position = "command"; - expansion = "NIXPKGS_ALLOW_UNFREE=1 nix % --impure"; - }; }; shellAliases = { del = "trash_file"; dev = "nix develop -c fish"; doom = "~/.config/emacs/bin/doom"; - repl = "NIXPKGS_ALLOW_UNFREE=1 nix repl --impure --extra-experimental-features 'flakes' nixpkgs.legacyPackages.x86_64-linux"; }; functions = { diff --git a/modules/home-manager/programs/neovim/.neoconf.json b/modules/home-manager/programs/neovim/.neoconf.json deleted file mode 100644 index 1a1be43..0000000 --- a/modules/home-manager/programs/neovim/.neoconf.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "neoconf": { - "plugins": { - "lua_ls": { - "enabled": true - } - } - }, - "lspconfig": { - "lua_ls": { - "Lua.completion.callSnippet": "Replace" - } - } -} diff --git a/modules/home-manager/programs/neovim/.stylua.toml b/modules/home-manager/programs/neovim/.stylua.toml deleted file mode 100644 index 3ee0ae0..0000000 --- a/modules/home-manager/programs/neovim/.stylua.toml +++ /dev/null @@ -1,5 +0,0 @@ -quote_style = "AutoPreferDouble" -call_parentheses = "None" - -[sort_requires] -enabled = true diff --git a/modules/home-manager/programs/neovim/default.nix b/modules/home-manager/programs/neovim/default.nix index 0cf20ce..367563f 100644 --- a/modules/home-manager/programs/neovim/default.nix +++ b/modules/home-manager/programs/neovim/default.nix @@ -49,7 +49,6 @@ in type = types.enum [ "amd" "nvidia" - "cpu" ]; }; }; @@ -70,20 +69,16 @@ in # Needed by LuaSnip luajitPackages.jsregexp - # Treesitter - gcc # For compiling languages - # CMAKE neocmakelsp # C/C++ clang-tools + gcc # Needed for treesitter vscode-extensions.ms-vscode.cpptools # C# - #csharp-ls Testing roslyn.nvim - roslyn-ls - rzls + csharp-ls csharpier netcoredbg @@ -119,7 +114,7 @@ in rust-analyzer cargo # Needed by blink-cmp taplo - #vscode-extensions.vadimcn.vscode-lldb # FIXME: Broken until MR 380775 hits nixpkgs-untable + vscode-extensions.vadimcn.vscode-lldb # Vue prettierd @@ -138,11 +133,6 @@ in source = ./lua; }; - xdg.configFile."nvim/queries" = { - recursive = true; - source = ./queries; - }; - xdg.configFile."nvim/lua/plugins/astrolsp.lua".source = pkgs.runCommand "astrolsp.lua" { } '' cp ${./lsp.lua} $out diff --git a/modules/home-manager/programs/neovim/lsp.lua b/modules/home-manager/programs/neovim/lsp.lua index 413048d..8d617a6 100644 --- a/modules/home-manager/programs/neovim/lsp.lua +++ b/modules/home-manager/programs/neovim/lsp.lua @@ -10,16 +10,16 @@ return { opts = { -- Configuration table of features provided by AstroLSP features = { - autoformat = true, -- enable or disable auto formatting on start - codelens = true, -- enable/disable codelens refresh on start - inlay_hints = false, -- enable/disable inlay hints on start + autoformat = true, -- enable or disable auto formatting on start + codelens = true, -- enable/disable codelens refresh on start + inlay_hints = false, -- enable/disable inlay hints on start semantic_tokens = true, -- enable/disable semantic token highlighting }, -- customize lsp formatting options formatting = { -- control auto formatting on save format_on_save = { - enabled = true, -- enable or disable format on save globally + enabled = true, -- enable or disable format on save globally allow_filetypes = { -- enable format on save for specified filetypes only -- "go", "c", @@ -55,7 +55,7 @@ return { "basedpyright", "clangd", "cmake", - --"csharp_ls", Testing roslyn.nvim + "csharp_ls", "cssls", "denols", "eslint", @@ -76,7 +76,6 @@ return { ---@diagnostic disable: missing-fields config = { -- clangd = { capabilities = { offsetEncoding = "utf-8" } }, - ---@type lspconfig.Config nixd = { settings = { nixd = { @@ -95,7 +94,6 @@ return { }, }, }, - ---@type lspconfig.Config vtsls = { filetypes = { "typescript", "javascript", "javascriptreact", "typescriptreact", "vue" }, settings = { @@ -114,7 +112,6 @@ return { }, }, }, - ---@type lspconfig.Config rust_analyzer = { settings = { ["rust-analyzer"] = { @@ -126,10 +123,6 @@ return { }, }, }, - ---@type lspconfig.Config - html = { - filetypes = { "html", "templ", "razor" }, - }, }, -- customize how language servers are attached handlers = { diff --git a/modules/home-manager/programs/neovim/lua/community.lua b/modules/home-manager/programs/neovim/lua/community.lua index 96d4822..13881f3 100644 --- a/modules/home-manager/programs/neovim/lua/community.lua +++ b/modules/home-manager/programs/neovim/lua/community.lua @@ -18,11 +18,9 @@ return { { import = "astrocommunity.motion.mini-ai" }, { import = "astrocommunity.motion.mini-surround" }, - { import = "astrocommunity.test.neotest" }, - { import = "astrocommunity.pack.cmake" }, { import = "astrocommunity.pack.cpp" }, - -- { import = "astrocommunity.pack.cs" }, Trying out roslyn.nvim + { import = "astrocommunity.pack.cs" }, { import = "astrocommunity.pack.godot" }, { import = "astrocommunity.pack.html-css" }, { import = "astrocommunity.pack.json" }, diff --git a/modules/home-manager/programs/neovim/lua/plugins/none-ls.lua b/modules/home-manager/programs/neovim/lua/plugins/none-ls.lua index 304876d..9a918b2 100644 --- a/modules/home-manager/programs/neovim/lua/plugins/none-ls.lua +++ b/modules/home-manager/programs/neovim/lua/plugins/none-ls.lua @@ -8,8 +8,8 @@ return { }, opts = function(_, config) -- config variable is the default configuration table for the setup function call - local null_ls = require "null-ls" - local helpers = require "null-ls.helpers" + local null_ls = require("null-ls") + local helpers = require("null-ls.helpers") -- local deno_fmt = helpers.make_builtin({ -- name = "deno_fmt", @@ -44,18 +44,16 @@ return { -- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/diagnostics config.sources = require("astrocore").list_insert_unique(config.sources, { -- Set a formatter - require "none-ls.diagnostics.flake8", - require "none-ls.formatting.ruff", - null_ls.builtins.formatting.clang_format.with { + require("none-ls.diagnostics.flake8"), + require("none-ls.formatting.ruff"), + null_ls.builtins.formatting.clang_format.with({ disabled_filetypes = { "cs" }, - }, + }), null_ls.builtins.formatting.csharpier, null_ls.builtins.formatting.nixfmt, null_ls.builtins.formatting.stylua, --deno_fmt, - null_ls.builtins.formatting.prettierd.with { - extra_filetypes = { "razor" }, - }, + null_ls.builtins.formatting.prettierd, null_ls.builtins.code_actions.statix, diff --git a/modules/home-manager/programs/neovim/lua/plugins/nvim-ufo.lua b/modules/home-manager/programs/neovim/lua/plugins/nvim-ufo.lua deleted file mode 100644 index bc14746..0000000 --- a/modules/home-manager/programs/neovim/lua/plugins/nvim-ufo.lua +++ /dev/null @@ -1,32 +0,0 @@ ----@type LazySpec -return { - "kevinhwang91/nvim-ufo", - opts = { - provider_selector = function(_, filetype, _) - ---@type table - local ftDefaults = { - cs = "treesitter", - } - - local function handleFallbackException(bufnr, err, providerName) - if type(err) == "string" and err:match("UfoFallbackException") then - return require("ufo").getFolds(bufnr, providerName) - else - return require("promise").reject(err) - end - end - - return ftDefaults[filetype] - or function(bufnr) - return require("ufo") - .getFolds(bufnr, "lsp") - :catch(function(err) - return handleFallbackException(bufnr, err, "treesitter") - end) - :catch(function(err) - return handleFallbackException(bufnr, err, "indent") - end) - end - end, - }, -} diff --git a/modules/home-manager/programs/neovim/lua/plugins/roslyn-nvim.lua b/modules/home-manager/programs/neovim/lua/plugins/roslyn-nvim.lua deleted file mode 100644 index 40cfe0a..0000000 --- a/modules/home-manager/programs/neovim/lua/plugins/roslyn-nvim.lua +++ /dev/null @@ -1,135 +0,0 @@ ----@type LazySpec -return { - { - "seblyng/roslyn.nvim", - ft = { "cs", "razor" }, - commit = "490fd2d0f76249032ef6ce503e43ccdaeed9616e", - lazy = true, - dependencies = { - { - "tris203/rzls.nvim", - config = function() - ---@diagnostic disable-next-line: missing-fields - require("rzls").setup { - path = vim.fn.getnixpath "rzls" .. "/bin/rzls", - } - end, - }, - }, - opts = function(_, opts) - local rzlspath = vim.fn.getnixpath "rzls" - require("roslyn.config").get() - - opts = { - exe = "Microsoft.CodeAnalysis.LanguageServer", - args = { - "--logLevel=Information", - "--extensionLogDirectory=" .. vim.fs.dirname(vim.lsp.get_log_path()), - "--razorSourceGenerator=" .. rzlspath .. "/lib/rzls/Microsoft.CodeAnalysis.Razor.Compiler.dll", - "--razorDesignTimePath=" - .. rzlspath - .. "/lib/rzls/Targets/Microsoft.NET.Sdk.Razor.DesignTime.targets", - }, - ---@type vim.lsp.ClientConfig - ---@diagnostic disable-next-line: missing-fields - config = { - handlers = require "rzls.roslyn_handlers", - settings = { - ["csharp|inlay_hints"] = { - csharp_enable_inlay_hints_for_implicit_object_creation = true, - csharp_enable_inlay_hints_for_implicit_variable_types = true, - - csharp_enable_inlay_hints_for_lambda_parameter_types = true, - csharp_enable_inlay_hints_for_types = true, - dotnet_enable_inlay_hints_for_indexer_parameters = true, - dotnet_enable_inlay_hints_for_literal_parameters = true, - dotnet_enable_inlay_hints_for_object_creation_parameters = true, - dotnet_enable_inlay_hints_for_other_parameters = true, - dotnet_enable_inlay_hints_for_parameters = true, - dotnet_suppress_inlay_hints_for_parameters_that_differ_only_by_suffix = true, - dotnet_suppress_inlay_hints_for_parameters_that_match_argument_name = true, - dotnet_suppress_inlay_hints_for_parameters_that_match_method_intent = true, - }, - ["csharp|code_lens"] = { - dotnet_enable_references_code_lens = true, - }, - }, - ---@class RoslynPatchedClient: vim.lsp.Client - ---@field patched boolean? - - ---@param client RoslynPatchedClient - ---@param bufnr integer - on_attach = function(client, bufnr) - -- Call AstroLSP's on_attach so it registers mappings, formatting, etc. - require("astrolsp").on_attach(client, bufnr) - - -- HACK: Patch out the `roslyn-ls` LSP client to have proper - -- semantic tokens. - -- This is a snippet of code taken and modified from: - -- https://github.com/seblyng/roslyn.nvim/wiki#semantic-tokens - if client.patched then - return - else - client.patched = true - end - - -- let the runtime know the server can do semanticTokens/full now - client.server_capabilities = vim.tbl_deep_extend("force", client.server_capabilities, { - semanticTokensProvider = { - full = true, - }, - }) - - local lsp_request = client.request - - client.request = function(method, params, handler, req_bufnr) - if method ~= vim.lsp.protocol.Methods.textDocument_semanticTokens_full then - return lsp_request(method, params, handler, req_bufnr) - end - - local target_bufnr = vim.uri_to_bufnr(params.textDocument.uri) - local line_count = vim.api.nvim_buf_line_count(target_bufnr) - local last_line = - vim.api.nvim_buf_get_lines(target_bufnr, line_count - 1, line_count, true)[1] - - local returnvalue = lsp_request("textDocument/semanticTokens/range", { - textDocument = params.textDocument, - range = { - ["start"] = { - line = 0, - character = 0, - }, - ["end"] = { - line = line_count - 1, - character = string.len(last_line) - 1, - }, - }, - }, handler, req_bufnr) - return returnvalue - end - end, - }, - } - - return opts - end, - init = function() - vim.filetype.add { - extension = { - razor = "razor", - cshtml = "razor", - }, - } - end, - }, - { - "nvim-neotest/neotest", - dependencies = { "Issafalcon/neotest-dotnet", config = function() end }, - opts = function(_, opts) - if not opts.adapters then - opts.adapters = {} - end - table.insert(opts.adapters, require "neotest-dotnet" (require("astrocore").plugin_opts "neotest-dotnet")) - end, - }, -} diff --git a/modules/home-manager/programs/neovim/lua/plugins/treesitter.lua b/modules/home-manager/programs/neovim/lua/plugins/treesitter.lua index ea0dec6..ee535af 100644 --- a/modules/home-manager/programs/neovim/lua/plugins/treesitter.lua +++ b/modules/home-manager/programs/neovim/lua/plugins/treesitter.lua @@ -2,57 +2,50 @@ ---@type LazySpec return { - "nvim-treesitter/nvim-treesitter", - ---@param _ LazyPlugin - ---@param opts TSConfig - opts = function(_, opts) - -- disable automatically installing parsers - opts.auto_install = false - - -- add more things to the ensure_installed table protecting against community packs modifying it - opts.ensure_installed = require("astrocore").list_insert_unique(opts.ensure_installed --[[@as string[]], { - -- Programming - "c", - "c_sharp", - "cmake", - "cpp", - "css", - "gdscript", - "godot_resource", - "html", - "hyprlang", - "javascript", - "jsdoc", - "lua", - "nim", - "nim_format_string", - "objc", - "proto", - "python", - "razor", - "svelte", - "tsx", - "typescript", - "vue", - -- Scripting - "bash", - "fish", - "glsl", - -- Configuring - "dockerfile", - "json", - "jsonc", - "nix", - "vhs", - "yaml", - -- Misc - "cuda", - "markdown", - "markdown_inline", - "query", - -- VIM - "vim", - "vimdoc", - }) - end, + "nvim-treesitter/nvim-treesitter", + opts = function(_, opts) + -- add more things to the ensure_installed table protecting against community packs modifying it + opts.ensure_installed = require("astrocore").list_insert_unique(opts.ensure_installed, { + -- Programming + "c", + "c_sharp", + "cmake", + "cpp", + "css", + "gdscript", + "godot_resource", + "html", + "hyprlang", + "javascript", + "jsdoc", + "lua", + "nim", + "nim_format_string", + "objc", + "proto", + "python", + "svelte", + "tsx", + "typescript", + "vue", + -- Scripting + "bash", + "glsl", + -- Configuring + "dockerfile", + "json", + "jsonc", + "nix", + "vhs", + "yaml", + -- Misc + "cuda", + "markdown", + "markdown_inline", + "query", + -- VIM + "vim", + "vimdoc", + }) + end, } diff --git a/modules/home-manager/programs/neovim/lua/plugins/user.lua b/modules/home-manager/programs/neovim/lua/plugins/user.lua index f2d900a..60b0925 100644 --- a/modules/home-manager/programs/neovim/lua/plugins/user.lua +++ b/modules/home-manager/programs/neovim/lua/plugins/user.lua @@ -85,7 +85,7 @@ return { { "xiyaowong/transparent.nvim", opts = function(_, opts) - local transparent = require "transparent" + local transparent = require("transparent") opts.groups = { "Comment", @@ -150,9 +150,9 @@ return { "WinSeparator", } - transparent.clear_prefix "BufferLine" - transparent.clear_prefix "Diagnostic" - transparent.clear_prefix "NvimTree" + transparent.clear_prefix("BufferLine") + transparent.clear_prefix("Diagnostic") + transparent.clear_prefix("NvimTree") end, }, @@ -160,9 +160,10 @@ return { { "jmbuhr/otter.nvim", dependencies = { + "hrsh7th/nvim-cmp", + "neovim/nvim-lspconfig", "nvim-treesitter/nvim-treesitter", }, - opts = {}, }, -- Adds highlighting and custom commands for ledger files diff --git a/modules/home-manager/programs/neovim/polish.lua b/modules/home-manager/programs/neovim/polish.lua index 092fe7c..9641c76 100644 --- a/modules/home-manager/programs/neovim/polish.lua +++ b/modules/home-manager/programs/neovim/polish.lua @@ -3,7 +3,7 @@ -- fit in the normal config locations above can go here -- Set up custom filetypes -vim.filetype.add { +vim.filetype.add({ extension = { foo = "fooscript", }, @@ -13,75 +13,9 @@ vim.filetype.add { pattern = { ["~/%.config/foo/.*"] = "fooscript", }, -} +}) ---- Define PackageOutput ---- @enum PackageOutput -local PACKAGEOUTPUT = { - out = 0, - lib = 1, -} - ---- Get the store path of a package ---- @param packagename NixSearchExceptions | string ---- @param packageoutput PackageOutput? ---- @return string | nil -vim.fn.getnixpath = function(packagename, packageoutput) - ---@enum (key) NixSearchExceptions - local exceptions = {} - - return vim.split( - vim.api.nvim_cmd( - vim.api.nvim_parse_cmd( - string.format( - "silent !nix eval --raw --expr 'with import { }; (%s).%s' --impure", - exceptions[packagename] or packagename, - (packageoutput == PACKAGEOUTPUT.out or packageoutput == nil) and "outPath" - or string.format("lib.getLib %s", packagename) - ), - {} - ), - { - output = true, - } - ), - "\n" - )[3] -end - ---- Helper function to allow me to run commands grabbed ---- by the current selection. ---- @param isLua boolean ---- @return string -vim.fn.runcmdonmark = function(isLua) - local beginRow, beginCol = unpack(vim.api.nvim_buf_get_mark(0, "<")) - local endRow, endCol = unpack(vim.api.nvim_buf_get_mark(0, ">")) - - if beginRow == nil or beginCol == nil or endRow == nil or endCol == nil then - return "" - end - - local text = table.concat( - vim.tbl_map(function(incoming) - return vim.trim(incoming) - end, vim.api.nvim_buf_get_text(0, beginRow - 1, beginCol, endRow - 1, endCol + 1, {})), - " " - ) - - vim.notify("Running expression: " .. text, vim.log.levels.INFO) - - return vim.api.nvim_cmd( - vim.api.nvim_parse_cmd((isLua == true and ":lua " or "") .. text, {}) --[[@as vim.api.keyset.cmd]], - {} - ) -end - ---- Register the function as a command as well, to facilitate things. -vim.api.nvim_create_user_command("RunCmdOnMark", function(opts) - vim.fn.runcmdonmark((opts.args == "v:false" or opts.args == "false") and false or true) -end, { range = true, nargs = "?" }) - -local dap = require "dap" +local dap = require("dap") -- @type DapAdapter dap.adapters.codelldb = { @@ -102,7 +36,7 @@ dap.adapters.cppdbg = { } -- @type DapAdapter -dap.adapters.netcoredbg = { +dap.adapters.coreclr = { type = "executable", command = "netcoredbg", args = { "--interpreter=vscode" }, @@ -160,23 +94,13 @@ dap.configurations.c = dap.configurations.cpp -- @type DapConfiguration dap.configurations.cs = { { - type = "netcoredbg", - name = "Launch DLL", + type = "coreclr", + name = "launch - netcoredbg", request = "launch", program = function() return vim.fn.input("Path to dll", vim.fn.getcwd() .. "/bin/Debug/", "file") end, }, - { - type = "netcoredbg", - name = "Attach to debugger", - request = "attach", - program = function() - return vim.fn.input("Path to dll", vim.fn.getcwd() .. "/bin/Debug/", "file") - end, - pid = "${command:pickProcess}", - cwd = "${workspaceFolder}", - }, } -- @type DapConfiguration diff --git a/modules/home-manager/programs/neovim/queries/c_sharp/folds.scm b/modules/home-manager/programs/neovim/queries/c_sharp/folds.scm deleted file mode 100644 index 2ec6b8b..0000000 --- a/modules/home-manager/programs/neovim/queries/c_sharp/folds.scm +++ /dev/null @@ -1,14 +0,0 @@ -;; extends - -; Capture entire regions for folding -( - (preproc_region) @region_begin - . - [ - (declaration) - (type_declaration) - ]* - . - (preproc_endregion) @region_end - (#make-range! "fold" @region_begin @region_end) -) diff --git a/specific/desktop/home-manager.nix b/specific/desktop/home-manager.nix index 2f7fbae..0b20301 100644 --- a/specific/desktop/home-manager.nix +++ b/specific/desktop/home-manager.nix @@ -126,7 +126,6 @@ # Enable ollama support ollama.enable = true; - ollama.type = "cpu"; }; modules.hyprland = { diff --git a/specific/desktop/services/jellyfin.nix b/specific/desktop/services/jellyfin.nix index c7e3f0a..badc27a 100644 --- a/specific/desktop/services/jellyfin.nix +++ b/specific/desktop/services/jellyfin.nix @@ -27,10 +27,5 @@ services.jellyseerr = { enable = true; openFirewall = true; - package = pkgs.jellyseerr.overrideAttrs ( - _final: _prev: { - dontCheckForBrokenSymlinks = true; - } - ); }; }