Something went wrong. Try again.
NixOS configuration
Something went wrong. Try again.
5.1 kB · 136 lines
Lua
at sway
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137return { { "folke/flash.nvim", event = "VeryLazy", vscode = true, ---@type Flash.Config opts = {}, -- stylua: ignore keys = { { "<leader>h", mode = { "n", "x", "o" }, function() require("flash").jump() end, desc = "Flash" }, { "<leader>H", mode = { "n", "o", "x" }, function() require("flash").treesitter() end, desc = "Flash Treesitter" }, { "<leader>r", mode = "o", function() require("flash").remote() end, desc = "Remote Flash" }, { "<leader>R", mode = { "o", "x" }, function() require("flash").treesitter_search() end, desc = "Treesitter Search" }, { "<c-s>", mode = { "c" }, function() require("flash").toggle() end, desc = "Toggle Flash Search" }, }, }, { "stevearc/conform.nvim", optional = true, opts = { formatters_by_ft = { nix = { "alejandra" }, }, }, }, -- Replace mini.pairs with nvim-pairs { "nvim-mini/mini.pairs", enabled = false, }, { "windwp/nvim-autopairs", event = "InsertEnter", config = true, -- use opts = {} for passing setup options -- this is equivalent to setup({}) function }, { "neovim/nvim-lspconfig", opts = { servers = { nixd = { settings = { nixd = { eval = { depth = 10, }, formatting = { command = { "alejandra" }, }, nixpkgs = { -- expr = "import <nixpkgs> { }", expr = [[ (builtins.getFlake ("git+file://" + toString ./.)).inputs.nixpkgs.legacyPackages.x86_64-linux ]], }, cmd = { "nixd", "--semantic-tokens=true" }, options = { nixos = { expr = '(builtins.getFlake ("git+file://" + toString ./../..)).nixosConfigurations.sachiel.options', }, home_manager = { expr = '(builtins.getFlake ("git+file://" + toString ./.)).homeConfigurations."${(builtins.getFlake ("git+file://" + toString ./.)).inputs.nix-secrets.username}".options', }, }, }, }, }, }, }, }, { "mfussenegger/nvim-lint", optional = true, opts = { linters_by_ft = { nix = { "statix" }, }, }, }, { "nvim-treesitter/nvim-treesitter", ---@type TSConfig ---@diagnostic disable-next-line: missing-fields opts = { ensure_installed = {}, incremental_selection = { keymaps = { init_selection = "<leader>a", node_incremental = "<leader>a", scope_incremental = false, node_decremental = "<bs>", }, }, }, }, { "mfussenegger/nvim-dap-python", config = function() require("dap-python").setup("python3") end, }, { "snacks.nvim", opts = { dashboard = { preset = { header = [[ ███▄ █ ▓█████ ▒█████ ██▒ █▓ ██▓ ███▄ ▄███▓ ██ ▀█ █ ▓█ ▀ ▒██▒ ██▒▓██░ █▒▓██▒▓██▒▀█▀ ██▒▓██ ▀█ ██▒▒███ ▒██░ ██▒ ▓██ █▒░▒██▒▓██ ▓██░▓██▒ ▐▌██▒▒▓█ ▄ ▒██ ██░ ▒██ █░░░██░▒██ ▒██ ▒██░ ▓██░░▒████▒░ ████▓▒░ ▒▀█░ ░██░▒██▒ ░██▒░ ▒░ ▒ ▒ ░░ ▒░ ░░ ▒░▒░▒░ ░ ▐░ ░▓ ░ ▒░ ░ ░░ ░░ ░ ▒░ ░ ░ ░ ░ ▒ ▒░ ░ ░░ ▒ ░░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ▒ ░░ ▒ ░░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ░ ]], -- stylua: ignore ---@type snacks.dashboard.Item[] keys = { { icon = " ", key = "f", desc = "Find File", action = ":lua Snacks.dashboard.pick('files')" }, { icon = " ", key = "n", desc = "Notes", action = ":Neorg workspace notes"}, { icon = " ", key = "e", desc = "New File", action = ":ene | startinsert" }, { icon = " ", key = "g", desc = "Find Text", action = ":lua Snacks.dashboard.pick('live_grep')" }, { icon = " ", key = "r", desc = "Recent Files", action = ":lua Snacks.dashboard.pick('oldfiles')" }, { icon = " ", key = "c", desc = "Config", action = ":lua Snacks.dashboard.pick('files', {cwd = vim.fn.stdpath('config')})" }, { icon = " ", key = "s", desc = "Restore Session", section = "session" }, { icon = " ", key = "x", desc = "Lazy Extras", action = ":LazyExtras" }, { icon = " ", key = "l", desc = "Lazy", action = ":Lazy" }, { icon = " ", key = "q", desc = "Quit", action = ":qa" }, }, }, }, }, },}