astro-nvim-v3 - change color line

This commit is contained in:
huyjaky
2025-01-06 12:17:40 +07:00
parent 9d867126d3
commit c0d55ff45e
9 changed files with 69 additions and 44 deletions

View File

@@ -27,7 +27,7 @@ return {
jedi_language_server = {
init_options = {
completion = {
-- disableSnippets = true,
disableSnippets = true,
},
diagnostics = {
enable = false,
@@ -36,6 +36,8 @@ return {
autoImportModules = {
"numpy",
"pandas",
"torch",
"sklearn"
},
},
},
@@ -44,6 +46,7 @@ return {
init_options = {
settings = {
lint = {
unfixable = { "F401" },
select = {
"ALL",
},
@@ -77,34 +80,16 @@ return {
"FIX002",
"N803",
"PD901",
"F401",
-- "F401",
"I001",
"RET504",
},
fixable = { "ALL" },
},
args = {},
},
},
},
pylsp = {
settings = {
pylsp = {
plugins = {
pyflakes = { enabled = false },
pycodestyle = { enabled = false },
autopep8 = { enabled = false },
yapf = { enabled = false },
mccabe = { enabled = false },
-- pylint = { enabled = false },
pylsp_mypy = { enabled = false },
pylsp_black = { enabled = false },
pylsp_isort = { enabled = false },
},
},
},
},
},
-- customize how language servers are attached
handlers = {
@@ -189,9 +174,11 @@ return {
on_attach = function(client, bufnr)
-- this would disable semanticTokensProvider for all clients
-- client.server_capabilities.semanticTokensProvider = nil
-- Disable ruff_lsp hover in favor of pyright
if client.name == "ruff_lsp" then client.server_capabilities.hoverProvider = false end
-- Disable completion feature of pyright
if client.name == "basedpyright" then client.server_capabilities.completionProvider = false end
end,
},
}

View File

@@ -18,10 +18,23 @@ return {
cmp.setup.filetype("python", {
sources = cmp.config.sources {
{ name = "nvim_lsp", priority = 700 },
{ name = "nvim_lsp", priority = 700},
{ name = "buffer", priority = 500 },
{ name = "path", priority = 250 },
},
sorting = {
comparators = {
cmp.config.compare.offset,
cmp.config.compare.exact,
cmp.config.compare.score,
cmp.config.compare.kind,
cmp.config.compare.sort_text,
cmp.config.compare.length,
cmp.config.compare.order,
},
priority_weight = 1000
},
})
return require("astrocore").extend_tbl(opts, {

View File

@@ -6,18 +6,18 @@ return {
end,
settings = {
basedpyright = {
disableOrganizeImports = true,
-- disableLanguageServices = true,
-- disableTaggedHints = true,
autoImportCompletions = false,
disableTaggedHints = true,
useLibraryCodeForTypes = false,
analysis = {
-- diagnosticMode = "workspace",
diagnosticMode = "openFilesOnly",
typeCheckingMode = "basic",
autoImportCompletions = false,
autoSearchPath = false,
logLevel = "error",
indexing = true,
indexing = false,
inlayHints = {
variableTypes = true,
functionReturnTypes = true,

View File

@@ -140,12 +140,12 @@ M.statusline = {
hl = { fg = "text_fg" },
padding = { right = 1 },
},
status.component.lsp {
lsp_client_names = {
icon = { kind = "ActiveLSP", padding = { right = 1 } },
},
surround = { separator = "left" },
},
-- status.component.lsp {
-- lsp_client_names = {
-- icon = { kind = "ActiveLSP", padding = { right = 1 } },
-- },
-- surround = { separator = "left" },
-- },
{
status.component.builder {
{ provider = get_icon "ScrollText" },

View File

@@ -11,11 +11,11 @@ return {
DiagnosticVirtualTextInfo = { fg = get_hlgroup("DiagnosticInfo").fg, bg = "none" },
DiagnosticVirtualTextWarn = { fg = get_hlgroup("DiagnosticWarn").fg, bg = "none" },
CursorLineNr = { fg = "#FFD700", bg = "none", bold = true },
CursorLine = { fg = "none", bg = "#004C4C", bold = true },
Visual = { fg = "#000000", bg = "#FFFFFF", bold = true },
-- remove background of inlay hints
LspInlayHint = { fg = get_hlgroup("LspInlayHint").fg, bg = "none" },
}
return hl
@@ -24,4 +24,3 @@ return {
-- Normal = { bg = "#000000" },
},
}

View File

@@ -1,6 +1,5 @@
-- Plugins to disable
return {
{ "nvim-neo-tree/neo-tree.nvim", enabled = true },
{ "s1n7ax/nvim-window-picker", enabled = false },
{ "akinsho/toggleterm.nvim", enabled = false },
{ "NvChad/nvim-colorizer.lua", enabled = false },
@@ -15,19 +14,26 @@ return {
{ "lukas-reineke/indent-blankline.nvim", enabled = false },
{ "chipsenkbeil/distant.nvim", enabled = false },
{ "gen740/SmoothCursor.nvim", enabled = false },
{ "stevearc/resession.nvim", enabled = true },
{ "AstroNvim/astrotheme", enabled = false },
{ "echasnovski/mini.move", enabled = true },
{ "scottmckendry/cyberdream.nvim", enabled = false },
{ "HiPhish/rainbow-delimiters.nvim", enabled = true },
{ "xiyaowong/transparent.nvim", enabled = true },
{ "xiyaowong/transparent.nvim", enabled = false },
{ "MagicDuck/grug-far.nvim", enabled = false },
{ "loctvl842/monokai-pro.nvim", enabled = false },
{ "xiyaowong/transparent.nvim", enabled = false },
{ "iamcco/markdown-preview.nvim", enabled = false },
{ "max397574/better-escape.nvim", enabled = false },
{ "ribru17/bamboo.nvim", enabled = true },
{ "hinell/duplicate.nvim", enabled = false },
{ "CRAG666/code_runner.nvim", enabled = false },
-- interface
{ "HiPhish/rainbow-delimiters.nvim", enabled = true },
{ "ribru17/bamboo.nvim", enabled = true },
-- service
{ "stevearc/resession.nvim", enabled = true },
{ "echasnovski/mini.move", enabled = true },
{ "nvim-neo-tree/neo-tree.nvim", enabled = true },
{ "folke/flash.nvim", enabled = true },
}

View File

@@ -14,7 +14,7 @@ return {
})
opts.highlight = {
enable = true,
disable = { "c", "rust", "tsx", "javascript"},
disable = { "c", "rust", "tsx", "javascript" },
additional_vim_regex_highlighting = false,
custom_captures = {
-- Highlight local variables

20
lua/plugins/whichkey.lua Normal file
View File

@@ -0,0 +1,20 @@
return {
"folke/which-key.nvim",
event = "VeryLazy",
opts = {
-- your configuration comes here
-- or leave it empty to use the default settings
-- refer to the configuration section below
preset = "helix",
layout = {
height = { min = 6 },
},
},
keys = {
{
"<leader>?",
function() require("which-key").show { global = false } end,
desc = "Buffer Local Keymaps (which-key)",
},
},
}