Compare commits
14 Commits
9ed93191d7
...
main
Author | SHA1 | Date | |
---|---|---|---|
4131381b91
|
|||
4378b50086
|
|||
a38b28e387
|
|||
5944d33bc1
|
|||
f0a54c0fa8
|
|||
85f8a9695a
|
|||
54b56d22be
|
|||
6c4eb08d89
|
|||
072121b538
|
|||
fa7579dd44
|
|||
16606b79d3
|
|||
61b3885595
|
|||
a25ddce9cb
|
|||
bbc65b11bb
|
@@ -12,3 +12,8 @@
|
||||
gpgsign = true
|
||||
[tag]
|
||||
gpgsign = true
|
||||
[filter "lfs"]
|
||||
process = git-lfs filter-process
|
||||
required = true
|
||||
clean = git-lfs clean -- %f
|
||||
smudge = git-lfs smudge -- %f
|
||||
|
@@ -1,4 +1,4 @@
|
||||
profile {
|
||||
output DP-1 mode 2560x1440 position 0,0
|
||||
output DP-3 mode 2560x1440 position 2560,0
|
||||
output DP-3 mode 2560x1440 position 2560,0
|
||||
}
|
||||
|
37
nvim/.config/nvim/init.lua
Normal file
37
nvim/.config/nvim/init.lua
Normal file
@@ -0,0 +1,37 @@
|
||||
vim.g.base46_cache = vim.fn.stdpath "data" .. "/base46/"
|
||||
vim.g.mapleader = " "
|
||||
|
||||
-- bootstrap lazy and all plugins
|
||||
local lazypath = vim.fn.stdpath "data" .. "/lazy/lazy.nvim"
|
||||
|
||||
if not vim.uv.fs_stat(lazypath) then
|
||||
local repo = "https://github.com/folke/lazy.nvim.git"
|
||||
vim.fn.system { "git", "clone", "--filter=blob:none", repo, "--branch=stable", lazypath }
|
||||
end
|
||||
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
local lazy_config = require "configs.lazy"
|
||||
|
||||
-- load plugins
|
||||
require("lazy").setup({
|
||||
{
|
||||
"NvChad/NvChad",
|
||||
lazy = false,
|
||||
branch = "v2.5",
|
||||
import = "nvchad.plugins",
|
||||
},
|
||||
|
||||
{ import = "plugins" },
|
||||
}, lazy_config)
|
||||
|
||||
-- load theme
|
||||
dofile(vim.g.base46_cache .. "defaults")
|
||||
dofile(vim.g.base46_cache .. "statusline")
|
||||
|
||||
require "options"
|
||||
require "nvchad.autocmds"
|
||||
|
||||
vim.schedule(function()
|
||||
require "mappings"
|
||||
end)
|
42
nvim/.config/nvim/lazy-lock.json
Normal file
42
nvim/.config/nvim/lazy-lock.json
Normal file
@@ -0,0 +1,42 @@
|
||||
{
|
||||
"LuaSnip": { "branch": "master", "commit": "b3104910bb5ebf40492aadffae18f2528fa757d9" },
|
||||
"NvChad": { "branch": "v2.5", "commit": "b5b38ebee53bcc8b71a917916ce61504ffffd509" },
|
||||
"base46": { "branch": "v3.0", "commit": "c3ee258239801e88eb6cd04c596cc292c88b91e5" },
|
||||
"cmp-async-path": { "branch": "main", "commit": "0ed1492f59e730c366d261a5ad822fa37e44c325" },
|
||||
"cmp-buffer": { "branch": "main", "commit": "b74fab3656eea9de20a9b8116afa3cfc4ec09657" },
|
||||
"cmp-nvim-lsp": { "branch": "main", "commit": "bd5a7d6db125d4654b50eeae9f5217f24bb22fd3" },
|
||||
"cmp-nvim-lua": { "branch": "main", "commit": "f12408bdb54c39c23e67cab726264c10db33ada8" },
|
||||
"cmp_luasnip": { "branch": "master", "commit": "98d9cb5c2c38532bd9bdb481067b20fea8f32e90" },
|
||||
"codesnap.nvim": { "branch": "main", "commit": "be6d6b9a3b5e6999edbda76b16dace03d9bfcd3d" },
|
||||
"conform.nvim": { "branch": "master", "commit": "b4aab989db276993ea5dcb78872be494ce546521" },
|
||||
"crates.nvim": { "branch": "main", "commit": "ac9fa498a9edb96dc3056724ff69d5f40b898453" },
|
||||
"friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "f780609807eca1f783a36a8a31c30a48fbe150c5" },
|
||||
"indent-blankline.nvim": { "branch": "master", "commit": "005b56001b2cb30bfa61b7986bc50657816ba4ba" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
|
||||
"mason.nvim": { "branch": "main", "commit": "7dc4facca9702f95353d5a1f87daf23d78e31c2a" },
|
||||
"menu": { "branch": "main", "commit": "7a0a4a2896b715c066cfbe320bdc048091874cc6" },
|
||||
"minty": { "branch": "main", "commit": "aafc9e8e0afe6bf57580858a2849578d8d8db9e0" },
|
||||
"mkdir.nvim": { "branch": "main", "commit": "c55d1dee4f099528a1853b28bb28caa802eba217" },
|
||||
"nvim-autopairs": { "branch": "master", "commit": "4d74e75913832866aa7de35e4202463ddf6efd1b" },
|
||||
"nvim-cmp": { "branch": "main", "commit": "b5311ab3ed9c846b585c0c15b7559be131ec4be9" },
|
||||
"nvim-dap": { "branch": "master", "commit": "7523676a4be17644587aa47e4d42f6f7646d4727" },
|
||||
"nvim-dap-go": { "branch": "main", "commit": "b4421153ead5d726603b02743ea40cf26a51ed5f" },
|
||||
"nvim-dap-python": { "branch": "master", "commit": "bfe572e4458e0ac876b9539a1e9f301c72db8ea0" },
|
||||
"nvim-dap-ui": { "branch": "master", "commit": "cf91d5e2d07c72903d052f5207511bf7ecdb7122" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "1f7fbc34e6420476142b5cc85e9bee52717540fb" },
|
||||
"nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" },
|
||||
"nvim-tree.lua": { "branch": "master", "commit": "e179ad2f83b5955ab0af653069a493a1828c2697" },
|
||||
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "6e51ca170563330e063720449c21f43e27ca0bc1" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
|
||||
"render-markdown.nvim": { "branch": "main", "commit": "67f2c7c8850bb11eefa6b22054a6f4cef1146de2" },
|
||||
"rust.vim": { "branch": "master", "commit": "889b9a7515db477f4cb6808bef1769e53493c578" },
|
||||
"rustaceanvim": { "branch": "master", "commit": "e9c5aaba16fead831379d5f44617547a90b913c7" },
|
||||
"sonarlint.nvim": { "branch": "main", "commit": "dc5702556f90eedce587233f3c1a0ae671ea3648" },
|
||||
"telescope.nvim": { "branch": "master", "commit": "b4da76be54691e854d3e0e02c36b0245f945c2c7" },
|
||||
"todo-comments.nvim": { "branch": "main", "commit": "304a8d204ee787d2544d8bc23cd38d2f929e7cc5" },
|
||||
"ui": { "branch": "v3.0", "commit": "532d566190391f2ddc388a5b1093b0f227366e87" },
|
||||
"volt": { "branch": "main", "commit": "620de1321f275ec9d80028c68d1b88b409c0c8b1" },
|
||||
"which-key.nvim": { "branch": "main", "commit": "370ec46f710e058c9c1646273e6b225acf47cbed" }
|
||||
}
|
47
nvim/.config/nvim/lua/chadrc.lua
Normal file
47
nvim/.config/nvim/lua/chadrc.lua
Normal file
@@ -0,0 +1,47 @@
|
||||
-- This file needs to have same structure as nvconfig.lua
|
||||
-- https://github.com/NvChad/ui/blob/v3.0/lua/nvconfig.lua
|
||||
-- Please read that file to know all available options :(
|
||||
|
||||
---@type ChadrcConfig
|
||||
local M = {}
|
||||
|
||||
M.base46 = {
|
||||
theme = "everforest",
|
||||
|
||||
-- hl_override = {
|
||||
-- Comment = { italic = true },
|
||||
-- ["@comment"] = { italic = true },
|
||||
-- },
|
||||
}
|
||||
|
||||
-- M.nvdash = { load_on_startup = true }
|
||||
-- M.ui = {
|
||||
-- tabufline = {
|
||||
-- lazyload = false
|
||||
-- }
|
||||
--}
|
||||
--
|
||||
M.mason = {
|
||||
pkgs = {
|
||||
"typescript-language-server",
|
||||
"eslint-lsp",
|
||||
"lua-language-server",
|
||||
"html-lsp",
|
||||
"pyright",
|
||||
"mypy",
|
||||
"ruff",
|
||||
"gopls",
|
||||
"goimports",
|
||||
"debugpy",
|
||||
"rust-analyzer",
|
||||
"codelldb",
|
||||
"tailwindcss-language-server",
|
||||
"golangci-lint-langserver",
|
||||
"typescript-language-server",
|
||||
"sonarlint-language-server",
|
||||
"lua-language-server",
|
||||
"clangd",
|
||||
},
|
||||
}
|
||||
|
||||
return M
|
20
nvim/.config/nvim/lua/configs/conform.lua
Normal file
20
nvim/.config/nvim/lua/configs/conform.lua
Normal file
@@ -0,0 +1,20 @@
|
||||
local options = {
|
||||
formatters_by_ft = {
|
||||
lua = { "stylua" },
|
||||
css = { "prettier" },
|
||||
html = { "prettier" },
|
||||
go = { "gopls" },
|
||||
ts = { "prettier" },
|
||||
tsx = { "prettier" },
|
||||
js = { "prettier" },
|
||||
jsx = { "prettier" }
|
||||
},
|
||||
|
||||
format_on_save = {
|
||||
-- These options will be passed to conform.format()
|
||||
timeout_ms = 500,
|
||||
lsp_fallback = true,
|
||||
},
|
||||
}
|
||||
|
||||
return options
|
47
nvim/.config/nvim/lua/configs/lazy.lua
Normal file
47
nvim/.config/nvim/lua/configs/lazy.lua
Normal file
@@ -0,0 +1,47 @@
|
||||
return {
|
||||
defaults = { lazy = true },
|
||||
install = { colorscheme = { "nvchad" } },
|
||||
|
||||
ui = {
|
||||
icons = {
|
||||
ft = "",
|
||||
lazy = " ",
|
||||
loaded = "",
|
||||
not_loaded = "",
|
||||
},
|
||||
},
|
||||
|
||||
performance = {
|
||||
rtp = {
|
||||
disabled_plugins = {
|
||||
"2html_plugin",
|
||||
"tohtml",
|
||||
"getscript",
|
||||
"getscriptPlugin",
|
||||
"gzip",
|
||||
"logipat",
|
||||
"netrw",
|
||||
"netrwPlugin",
|
||||
"netrwSettings",
|
||||
"netrwFileHandlers",
|
||||
"matchit",
|
||||
"tar",
|
||||
"tarPlugin",
|
||||
"rrhelper",
|
||||
"spellfile_plugin",
|
||||
"vimball",
|
||||
"vimballPlugin",
|
||||
"zip",
|
||||
"zipPlugin",
|
||||
"tutor",
|
||||
"rplugin",
|
||||
"syntax",
|
||||
"synmenu",
|
||||
"optwin",
|
||||
"compiler",
|
||||
"bugreport",
|
||||
"ftplugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
108
nvim/.config/nvim/lua/configs/lspconfig.lua
Normal file
108
nvim/.config/nvim/lua/configs/lspconfig.lua
Normal file
@@ -0,0 +1,108 @@
|
||||
-- load defaults i.e lua_lsp
|
||||
require("nvchad.configs.lspconfig").defaults()
|
||||
|
||||
local lspconfig = vim.lsp.config
|
||||
local lsputil = require("lspconfig.util")
|
||||
|
||||
-- EXAMPLE
|
||||
local servers = { "html", "cssls" }
|
||||
local nvlsp = require("nvchad.configs.lspconfig")
|
||||
|
||||
-- lsps with default config
|
||||
for _, lsp in ipairs(servers) do
|
||||
lspconfig(lsp, {
|
||||
on_attach = nvlsp.on_attach,
|
||||
on_init = nvlsp.on_init,
|
||||
capabilities = nvlsp.capabilities,
|
||||
})
|
||||
end
|
||||
|
||||
lspconfig("gopls", {
|
||||
on_attach = nvlsp.on_attach,
|
||||
capabilities = nvlsp.capabilities,
|
||||
cmd = { "gopls" },
|
||||
filetypes = { "go", "gomod", "gowork", "gotmpl" },
|
||||
settings = {
|
||||
completeUnimported = true,
|
||||
usePlaceholders = true,
|
||||
analyses = {
|
||||
unusedparams = true,
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
lspconfig("ts_ls", {
|
||||
on_attach = nvlsp.on_attach,
|
||||
capabilities = nvlsp.capabilities,
|
||||
init_options = {
|
||||
preferences = {
|
||||
disableSuggestions = true,
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
lspconfig("tailwindcss", {
|
||||
on_attach = nvlsp.on_attach,
|
||||
capabilities = nvlsp.capabilities,
|
||||
})
|
||||
|
||||
lspconfig("pyright", {
|
||||
on_attach = nvlsp.on_attach,
|
||||
capabilities = nvlsp.capabilities,
|
||||
filetypes = { "python" },
|
||||
})
|
||||
|
||||
lspconfig("eslint", {
|
||||
on_attach = nvlsp.on_attach,
|
||||
capabilities = nvlsp.capabilities,
|
||||
})
|
||||
|
||||
lspconfig("golangcilsp", {
|
||||
default_config = {
|
||||
cmd = { "golangci-lint-langserver" },
|
||||
root_dir = lsputil.root_pattern(".git", "go.mod"),
|
||||
init_options = {
|
||||
command = {
|
||||
"golangci-lint",
|
||||
"run",
|
||||
"--output.json.path",
|
||||
"stdout",
|
||||
"--show-stats=false",
|
||||
"--issues-exit-code=1",
|
||||
},
|
||||
},
|
||||
},
|
||||
})
|
||||
|
||||
lspconfig("golangci_lint_ls", {
|
||||
filetypes = { "go", "gomod" },
|
||||
})
|
||||
|
||||
lspconfig("clangd", {
|
||||
filetypes = { "c" },
|
||||
})
|
||||
|
||||
require("sonarlint").setup({
|
||||
server = {
|
||||
cmd = {
|
||||
"sonarlint-language-server",
|
||||
-- Ensure that sonarlint-language-server uses stdio channel
|
||||
"-stdio",
|
||||
"-analyzers",
|
||||
vim.fn.expand("$MASON/share/nvim/mason/share/sonarlint-analyzers/sonargo.jar"),
|
||||
vim.fn.expand("$MASON/share/sonarlint-analyzers/sonarpython.jar"),
|
||||
vim.fn.expand("$MASON/share/sonarlint-analyzers/sonarjs.jar"),
|
||||
},
|
||||
settings = {
|
||||
sonarlint = {
|
||||
test = "test",
|
||||
},
|
||||
},
|
||||
},
|
||||
filetypes = {
|
||||
"python",
|
||||
"go",
|
||||
"javascript",
|
||||
"typescript",
|
||||
},
|
||||
})
|
@@ -1,9 +0,0 @@
|
||||
local M = {}
|
||||
|
||||
M.ui = { theme = 'catppuccin', tabufline= {enabled= false} }
|
||||
M.plugins = "custom.plugins"
|
||||
M.mappings = require "custom.configs.mappings"
|
||||
vim.opt.spelllang = 'en_gb'
|
||||
vim.opt.spell = true
|
||||
|
||||
return M
|
@@ -1,36 +0,0 @@
|
||||
local on_attach = require("plugins.configs.lspconfig").on_attach
|
||||
local capabilities = require("plugins.configs.lspconfig").capabilities
|
||||
|
||||
local lspconfig = require("lspconfig")
|
||||
local util = require "lspconfig/util"
|
||||
|
||||
lspconfig.gopls.setup {
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
cmd= {"gopls"},
|
||||
filetypes = { "go", "gomod", "gowork", "gotmpl" },
|
||||
root_dir = util.root_pattern("go.work", "go.mod", ".git"),
|
||||
settings = {
|
||||
completeUnimported = true,
|
||||
usePlaceholders = true,
|
||||
analyses = {
|
||||
unusedparams = true,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
lspconfig.tsserver.setup{
|
||||
on_attach=on_attach,
|
||||
capabilities=capabilities,
|
||||
init_options = {
|
||||
preferences = {
|
||||
disableSuggestions = true,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
lspconfig.pyright.setup({
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
filetypes= {"python"},
|
||||
})
|
@@ -1,48 +0,0 @@
|
||||
local M = {}
|
||||
|
||||
M.dap = {
|
||||
plugin = true,
|
||||
n = {
|
||||
["<leader>db"] = {
|
||||
"<cmd> DapToggleBreakpoint <CR>",
|
||||
"Add breakpoint at line"
|
||||
},
|
||||
["<leader>dus"] = {
|
||||
function ()
|
||||
local widgets = require("dap.ui.widgets");
|
||||
local sidebar = widgets.sidebar(widgets.scopes);
|
||||
sidebar.open();
|
||||
end,
|
||||
"open debugging sidebar"
|
||||
}
|
||||
}
|
||||
}
|
||||
M.dap_go = {
|
||||
plugin=true,
|
||||
n = {
|
||||
["<leader>gdt"] = {
|
||||
function()
|
||||
require("dap-go").debug_test()
|
||||
end,
|
||||
"Debug go test"
|
||||
},
|
||||
["<leader>gdl"] = {
|
||||
function()
|
||||
require("dap-go").debug_last()
|
||||
end,
|
||||
"Debug last go test"
|
||||
}
|
||||
}
|
||||
}
|
||||
M.dapui = {
|
||||
n = {
|
||||
["<leader>dui"] = {
|
||||
function()
|
||||
require("dapui").toggle()
|
||||
end,
|
||||
"Open debuging ui"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return M
|
@@ -1,29 +0,0 @@
|
||||
local null_ls = require("null-ls")
|
||||
local augroup = vim.api.nvim_create_augroup("LspFormatting", {})
|
||||
|
||||
local opts = {
|
||||
sources = {
|
||||
null_ls.builtins.formatting.gofmt,
|
||||
null_ls.builtins.formatting.goimports,
|
||||
null_ls.builtins.diagnostics.mypy,
|
||||
null_ls.builtins.diagnostics.ruff,
|
||||
null_ls.builtins.formatting.eslint,
|
||||
null_ls.builtins.formatting.prettier,
|
||||
},
|
||||
on_attach = function(client, bufnr)
|
||||
if client.supports_method("textDocument/formatting") then
|
||||
vim.api.nvim_clear_autocmds({
|
||||
group = augroup,
|
||||
buffer = bufnr,
|
||||
})
|
||||
vim.api.nvim_create_autocmd("BufWritePre", {
|
||||
group = augroup,
|
||||
buffer = bufnr,
|
||||
callback = function()
|
||||
vim.lsp.buf.format({ bufnr = bufnr })
|
||||
end,
|
||||
})
|
||||
end
|
||||
end,
|
||||
}
|
||||
return opts
|
@@ -1,9 +0,0 @@
|
||||
|
||||
local null_ls = require("null-ls")
|
||||
local opts = {
|
||||
sources = {
|
||||
null_ls.builtins.diagnostics.mypy,
|
||||
null_ls.builtins.diagnostics.ruff,
|
||||
},
|
||||
}
|
||||
return opts
|
@@ -1,25 +0,0 @@
|
||||
local null_ls = require("null-ls")
|
||||
local augroup = vim.api.nvim_create_augroup("LspFormatting", {})
|
||||
|
||||
local opts = {
|
||||
sources = {
|
||||
null_ls.builtins.formatting.eslint,
|
||||
null_ls.builtins.formatting.prettier,
|
||||
},
|
||||
on_attach = function(client, bufnr)
|
||||
if client.supports_method("textDocument/formatting") then
|
||||
vim.api.nvim_clear_autocmds({
|
||||
group = augroup,
|
||||
buffer = bufnr,
|
||||
})
|
||||
vim.api.nvim_create_autocmd("BufWritePre", {
|
||||
group = augroup,
|
||||
buffer = bufnr,
|
||||
callback = function()
|
||||
vim.lsp.buf.format({ bufnr = bufnr })
|
||||
end,
|
||||
})
|
||||
end
|
||||
end,
|
||||
}
|
||||
return opts
|
@@ -1,80 +0,0 @@
|
||||
local plugins = {
|
||||
{
|
||||
"williamboman/mason.nvim",
|
||||
opts = {
|
||||
ensure_installed = {
|
||||
"typescript-language-server",
|
||||
"eslint-lsp",
|
||||
"lua-language-server",
|
||||
"html-lsp",
|
||||
"pyright",
|
||||
"mypy",
|
||||
"ruff",
|
||||
"gopls",
|
||||
"goimports",
|
||||
"debugpy",
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
config=function ()
|
||||
require "plugins.configs.lspconfig"
|
||||
require "custom.configs.lspconfig"
|
||||
end,
|
||||
},{
|
||||
"jose-elias-alvarez/null-ls.nvim",
|
||||
ft = "go",
|
||||
opts = function()
|
||||
return require "custom.configs.null-ls-go"
|
||||
end,
|
||||
}, {
|
||||
"mfussenegger/nvim-dap",
|
||||
init = function()
|
||||
require("core.utils").load_mappings("dap")
|
||||
end
|
||||
}, {
|
||||
"leoluz/nvim-dap-go",
|
||||
ft = "go",
|
||||
dependencies = "mfussenegger/nvim-dap",
|
||||
config = function (_, opts)
|
||||
require("dap-go").setup(opts)
|
||||
require("core.utils").load_mappings("dap_go")
|
||||
require('dap.ext.vscode').load_launchjs(nil, {})
|
||||
end
|
||||
},{
|
||||
"mfussenegger/nvim-dap-python",
|
||||
ft = "python",
|
||||
dependencies = "mfussenegger/nvim-dap",
|
||||
config = function (_, opts)
|
||||
local path = "~/.local/share/nvim/mason/packages/debugpy/venv/bin/python"
|
||||
require("dap-python").setup(path)
|
||||
end
|
||||
},
|
||||
{
|
||||
"NVChad/nvim-autopairs",
|
||||
enabled = false
|
||||
},
|
||||
{
|
||||
"rcarriga/nvim-dap-ui",
|
||||
init = function()
|
||||
require("dapui").setup()
|
||||
vim.fn.sign_define('DapBreakpoint', { text = '🐞' })
|
||||
vim.fn.sign_define('DapBreakpointRejected', { text = '🐞' })
|
||||
local dap, dapui = require("dap"), require("dapui")
|
||||
dap.listeners.before.attach.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.launch.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.event_terminated.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
dap.listeners.before.event_exited.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
end
|
||||
}
|
||||
}
|
||||
return plugins
|
25
nvim/.config/nvim/lua/mappings.lua
Normal file
25
nvim/.config/nvim/lua/mappings.lua
Normal file
@@ -0,0 +1,25 @@
|
||||
require("nvchad.mappings")
|
||||
|
||||
local map = vim.keymap.set
|
||||
|
||||
map("n", "]g", function()
|
||||
vim.diagnostic.jump({ count = 1, float = true })
|
||||
end)
|
||||
|
||||
map("n", "[g", function()
|
||||
vim.diagnostic.jump({ count = -1, float = true })
|
||||
end)
|
||||
|
||||
map("n", "<leader>ww", function()
|
||||
vim.diagnostic.open_float()
|
||||
end)
|
||||
|
||||
map("n", "<leader>of", ":browse oldfiles\n")
|
||||
|
||||
map("n", "]t", function()
|
||||
require("todo-comments").jump_next()
|
||||
end, { desc = "Next todo comment" })
|
||||
|
||||
map("n", "[t", function()
|
||||
require("todo-comments").jump_prev()
|
||||
end, { desc = "Previous todo comment" })
|
1
nvim/.config/nvim/lua/options.lua
Normal file
1
nvim/.config/nvim/lua/options.lua
Normal file
@@ -0,0 +1 @@
|
||||
require "nvchad.options"
|
130
nvim/.config/nvim/lua/plugins/init.lua
Normal file
130
nvim/.config/nvim/lua/plugins/init.lua
Normal file
@@ -0,0 +1,130 @@
|
||||
return {
|
||||
{
|
||||
"stevearc/conform.nvim",
|
||||
event = "BufWritePre", -- uncomment for format on save
|
||||
opts = require("configs.conform"),
|
||||
},
|
||||
{
|
||||
"jghauser/mkdir.nvim",
|
||||
},
|
||||
{
|
||||
"MeanderingProgrammer/render-markdown.nvim",
|
||||
opts = {
|
||||
file_types = { "markdown", "Avante" },
|
||||
},
|
||||
ft = { "markdown", "Avante" },
|
||||
},
|
||||
"nvim-lua/plenary.nvim",
|
||||
{
|
||||
"folke/todo-comments.nvim",
|
||||
dependencies = { "nvim-lua/plenary.nvim" },
|
||||
opts = {},
|
||||
},
|
||||
{
|
||||
"neovim/nvim-lspconfig",
|
||||
config = function()
|
||||
require("configs.lspconfig")
|
||||
end,
|
||||
},
|
||||
{ "nvim-neotest/nvim-nio" },
|
||||
{
|
||||
"mistricky/codesnap.nvim",
|
||||
build = "make build_generator",
|
||||
keys = {
|
||||
{ "<leader>cc", "<cmd>CodeSnap<cr>", mode = "x", desc = "Save selected code snapshot into clipboard" },
|
||||
{ "<leader>cs", "<cmd>CodeSnapSave<cr>", mode = "x", desc = "Save selected code snapshot in ~/Pictures" },
|
||||
},
|
||||
opts = {
|
||||
save_path = "~/Pictures",
|
||||
has_breadcrumbs = false,
|
||||
bg_theme = "bamboo",
|
||||
watermark = "",
|
||||
mac_window_bar = false,
|
||||
},
|
||||
},
|
||||
{
|
||||
"mfussenegger/nvim-dap",
|
||||
},
|
||||
{
|
||||
"leoluz/nvim-dap-go",
|
||||
ft = "go",
|
||||
dependencies = "mfussenegger/nvim-dap",
|
||||
config = function(_, opts)
|
||||
require("dap-go").setup(opts)
|
||||
-- require("core.utils").load_mappings("dap_go")
|
||||
require("dap.ext.vscode").load_launchjs(nil, {})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"mfussenegger/nvim-dap-python",
|
||||
ft = "python",
|
||||
dependencies = "mfussenegger/nvim-dap",
|
||||
config = function(_, _)
|
||||
local path = "~/.local/share/nvim/mason/packages/debugpy/venv/bin/python"
|
||||
require("dap-python").setup(path)
|
||||
end,
|
||||
},
|
||||
{
|
||||
"NVChad/nvim-autopairs",
|
||||
enabled = false,
|
||||
},
|
||||
{
|
||||
"mrcjkb/rustaceanvim",
|
||||
version = "^5", -- Recommended
|
||||
lazy = false, -- This plugin is already lazy
|
||||
},
|
||||
{
|
||||
"rust-lang/rust.vim",
|
||||
ft = "rust",
|
||||
init = function()
|
||||
vim.g.rustfmt_autosave = 1
|
||||
end,
|
||||
},
|
||||
{
|
||||
"saecki/crates.nvim",
|
||||
ft = { "rust", "toml" },
|
||||
config = function(_, opts)
|
||||
local crates = require("crates")
|
||||
crates.setup(opts)
|
||||
crates.show()
|
||||
end,
|
||||
},
|
||||
{
|
||||
"rcarriga/nvim-dap-ui",
|
||||
init = function()
|
||||
require("dapui").setup()
|
||||
vim.fn.sign_define("DapBreakpoint", { text = "🐞" })
|
||||
vim.fn.sign_define("DapBreakpointRejected", { text = "🐞" })
|
||||
local dap, dapui = require("dap"), require("dapui")
|
||||
dap.listeners.before.attach.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.launch.dapui_config = function()
|
||||
dapui.open()
|
||||
end
|
||||
dap.listeners.before.event_terminated.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
dap.listeners.before.event_exited.dapui_config = function()
|
||||
dapui.close()
|
||||
end
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
opts = {
|
||||
ensure_installed = {
|
||||
"vim",
|
||||
"lua",
|
||||
"vimdoc",
|
||||
"html",
|
||||
"css",
|
||||
},
|
||||
},
|
||||
{
|
||||
url = "https://gitlab.com/schrieveslaach/sonarlint.nvim",
|
||||
dependencies = "neovim/nvim-lspconfig",
|
||||
ft = { "python", "go", "js", "ts" },
|
||||
},
|
||||
},
|
||||
}
|
18
nvim/.config/nvim/lua/rust-tools.lua
Normal file
18
nvim/.config/nvim/lua/rust-tools.lua
Normal file
@@ -0,0 +1,18 @@
|
||||
local on_attach = require("plugins.configs.lspconfig").on_attach
|
||||
local capabilities = require("plugins.configs.lspconfig").capabilities
|
||||
|
||||
local options = {
|
||||
server = {
|
||||
on_attach = on_attach,
|
||||
capabilities = capabilities,
|
||||
},
|
||||
dap = {
|
||||
adapter = {
|
||||
type = "executable",
|
||||
command = "lldb-vscode",
|
||||
name = "rt_lldb",
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
return options
|
3
nvim/.config/nvim/spell/en.utf-8.add
Normal file
3
nvim/.config/nvim/spell/en.utf-8.add
Normal file
@@ -0,0 +1,3 @@
|
||||
feat
|
||||
Errored
|
||||
Dreamkiln
|
BIN
nvim/.config/nvim/spell/en.utf-8.add.spl
Normal file
BIN
nvim/.config/nvim/spell/en.utf-8.add.spl
Normal file
Binary file not shown.
@@ -1,2 +1,7 @@
|
||||
Host gitea
|
||||
IdentityFile /home/matt/.ssh/lightsail_rsa
|
||||
User admin
|
||||
Host minecraft
|
||||
IdentityFile /home/matt/.ssh/minecraft_private.pem
|
||||
Host *
|
||||
IdentityFile /home/matt/.ssh/id_ed25519_sk_desk
|
||||
|
@@ -28,11 +28,13 @@ set $term alacritty
|
||||
# Note: pass the final command to swaymsg so that the resulting window can be opened
|
||||
# on the original workspace that the command was run on.
|
||||
set $menu rofi -show drun
|
||||
set $emoji rofi -modi emoji -show emoji -kb-secondary-copy "" -kb-custom-1 Ctrl+c
|
||||
### Output configuration
|
||||
#
|
||||
# Default wallpaper (more resolutions are available in /usr/share/backgrounds/sway/)
|
||||
set $background /home/matt/Photos/wallpaper.png
|
||||
output * bg $background fill
|
||||
output DP-1 bg /home/matt/Photos/Wallpapers/left.jpg fill
|
||||
output DP-3 bg /home/matt/Photos/Wallpapers/right.jpg fill
|
||||
#
|
||||
# Example configuration:
|
||||
#
|
||||
@@ -85,6 +87,8 @@ input "Logitech G502 HERO Gaming Mouse" {
|
||||
# Start your launcher
|
||||
bindsym $mod+d exec $menu
|
||||
|
||||
bindsym Mod4+period exec $emoji
|
||||
|
||||
# Drag floating windows by holding down $mod and left mouse button.
|
||||
# Resize them with right mouse button + $mod.
|
||||
# Despite the name, also works for non-floating windows.
|
||||
|
@@ -4,7 +4,7 @@
|
||||
"modules-left": [
|
||||
"sway/workspaces"
|
||||
],
|
||||
"modules-right": ["pulseaudio", "custom/wireguard", "backlight", "network", "cpu", "memory", "disk", "temperature", "battery", "clock", "tray"],
|
||||
"modules-right": ["cava", "pulseaudio", "custom/wireguard", "backlight", "network", "cpu", "memory", "disk", "temperature", "battery", "clock", "tray"],
|
||||
"cpu": {
|
||||
"format": "CPU: {usage}%"
|
||||
},
|
||||
@@ -24,9 +24,34 @@
|
||||
"disk": {
|
||||
"format": "{free}"
|
||||
},
|
||||
"clock": {
|
||||
"format": "{:%Y:%m:%d %T}",
|
||||
"interval": 1
|
||||
},
|
||||
"custom/wireguard": {
|
||||
"exec": "~/.config/waybar/scripts/wireguard.sh",
|
||||
"on-click": "~/.config/waybar/scripts/wireguard.sh --toggle",
|
||||
"interval": 2
|
||||
}
|
||||
},
|
||||
"cava": {
|
||||
"framerate": 30,
|
||||
"autosens": 1,
|
||||
"sensitivity": 100,
|
||||
"bars": 14,
|
||||
"lower_cutoff_freq": 50,
|
||||
"higher_cutoff_freq": 10000,
|
||||
"method": "pulse",
|
||||
"source": "auto",
|
||||
"stereo": true,
|
||||
"reverse": false,
|
||||
"bar_delimiter": 0,
|
||||
"monstercat": false,
|
||||
"waves": false,
|
||||
"noise_reduction": 0.77,
|
||||
"input_delay": 2,
|
||||
"format-icons" : ["▁", "▂", "▃", "▄", "▅", "▆", "▇", "█" ],
|
||||
"actions": {
|
||||
"on-click-right": "mode"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user