astro-nvim-v3 - uptostate

This commit is contained in:
huyjaky
2025-08-16 19:57:11 +07:00
parent 182ad7856a
commit 4b6f99b5a8
16 changed files with 248 additions and 228 deletions

View File

@@ -13,7 +13,7 @@ return {
large_buf = { size = 1024 * 500, lines = 10000 }, -- set global limits for large files for disabling features like treesitter
autopairs = false, -- enable autopairs at start
cmp = true, -- enable completion at start
diagnostics_mode = 2, -- diagnostic mode on start (0 = off, 1 = no signs/virtual text, 2 = no virtual text, 3 = on)
diagnostics_mode = 1, -- diagnostic mode on start (0 = off, 1 = no signs/virtual text, 2 = no virtual text, 3 = on)
highlighturl = false, -- highlight URLs at start
notifications = true, -- enable notifications at start
},
@@ -27,7 +27,7 @@ return {
sessions = {
-- Configure auto saving
autosave = {
last = true, -- auto save last session
last = false, -- auto save last session
cwd = false, -- auto save session for each working directory
},
-- Patterns to ignore when saving sessions

View File

@@ -16,6 +16,5 @@ return {
icons = require "plugins.configs.ui.icons",
status = require "plugins.configs.ui.status",
lazygit = false,
},
}

View File

@@ -3,6 +3,8 @@ local function has_words_before()
return col ~= 0 and vim.api.nvim_buf_get_lines(0, line - 1, line, true)[1]:sub(col, col):match("%s") == nil
end
return {
{
"github/copilot.vim",

View File

@@ -1,30 +1,31 @@
return {
init_options = {
completion = {
disableSnippets = true,
},
diagnostics = {
enable = false,
},
hover = {
enable = true,
},
workspace = {
environmentPath = "/home/duckq1u/miniconda3/envs/OCR3/bin/python",
ignore = {
"/home/duckq1u/miniconda3/envs/OCR3/lib/python3.11/site-packages/transformers/mode ls/albert/configuration_albert.py",
},
},
init_options = {
completion = {
disableSnippets = true,
},
diagnostics = {
enable = false,
},
hover = {
enable = true,
},
workspace = {
-- environmentPath = "/home/duckq1u/miniconda3/envs/OCR3/bin/python",
environmentPath = vim.fn.exepath("python"),
ignore = {
"/home/duckq1u/miniconda3/envs/OCR3/lib/python3.11/site-packages/transformers/mode ls/albert/configuration_albert.py",
},
},
jediSettings = {
autoImportModules = {
"numpy",
"pandas",
"torch",
-- "torchmetrics",
-- "pytorch_lightning",
},
},
},
jediSettings = {
autoImportModules = {
"numpy",
"pandas",
"torch",
-- "torchmetrics",
-- "pytorch_lightning",
},
},
},
}

View File

@@ -1,61 +1,59 @@
-- Plugins to disable
return {
{ "s1n7ax/nvim-window-picker", enabled = false },
{ "akinsho/toggleterm.nvim", enabled = false },
{ "NvChad/nvim-colorizer.lua", enabled = false },
{ "catppuccin/nvim", name = "catppuccin", enabled = false },
{ "rebelot/kanagawa.nvim", enabled = false },
{ "folke/tokyonight.nvim", enabled = false },
{ "f4z3r/gruvbox-material.nvim", name = "gruvbox-material", enabled = false },
{ "b0o/SchemaStore.nvim", enabled = false },
{ "ray-x/lsp_signature.nvim", enabled = false },
{ "kmontocam/nvim-conda", enabled = false },
{ "NMAC427/guess-indent.nvim", enabled = false },
{ "lukas-reineke/indent-blankline.nvim", enabled = false },
{ "AstroNvim/astrotheme", enabled = false },
{ "scottmckendry/cyberdream.nvim", enabled = false },
{ "xiyaowong/transparent.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 },
{ "hinell/duplicate.nvim", enabled = false },
{ "CRAG666/code_runner.nvim", enabled = false },
{ "RRethy/vim-illuminate", enabled = false },
-- { "OXY2DEV/markview.nvim", enabled = false },
{ "kevinhwang91/nvim-ufo", enabled = false },
{ "echasnovski/mini.bufremove", enabled = false },
{ "s1n7ax/nvim-window-picker", enabled = false },
{ "akinsho/toggleterm.nvim", enabled = false },
{ "NvChad/nvim-colorizer.lua", enabled = false },
{ "catppuccin/nvim", name = "catppuccin", enabled = false },
{ "rebelot/kanagawa.nvim", enabled = false },
{ "folke/tokyonight.nvim", enabled = false },
{ "f4z3r/gruvbox-material.nvim", name = "gruvbox-material", enabled = false },
{ "b0o/SchemaStore.nvim", enabled = false },
{ "ray-x/lsp_signature.nvim", enabled = false },
{ "kmontocam/nvim-conda", enabled = false },
{ "NMAC427/guess-indent.nvim", enabled = false },
{ "lukas-reineke/indent-blankline.nvim", enabled = false },
{ "AstroNvim/astrotheme", enabled = false },
{ "scottmckendry/cyberdream.nvim", enabled = false },
{ "xiyaowong/transparent.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 },
{ "hinell/duplicate.nvim", enabled = false },
{ "CRAG666/code_runner.nvim", enabled = false },
{ "RRethy/vim-illuminate", enabled = false },
{ "kevinhwang91/nvim-ufo", enabled = false },
{ "echasnovski/mini.bufremove", enabled = false },
{ "hrsh7th/nvim-cmp", enabled = false },
{ "rcarriga/cmp-dap", enabled = false },
{ "hrsh7th/nvim-cmp", enabled = false },
{ "rcarriga/cmp-dap", enabled = false },
-- System
{ "nvim-treesitter/nvim-treesitter-textobjects", enabled = false },
-- Disable Dap
{ "mfussenegger/nvim-dap", enabled = false },
{ "theHamsta/nvim-dap-virtual-text", enabled = false },
{ "rcarriga/nvim-dap-ui", enabled = false },
{ "jay-babu/mason-nvim-dap.nvim", enabled = false },
-- { "jay-babu/mason-null-ls.nvim", enabled = false },
{ "b0o/schemastore.nvim", enabled = false },
{ "Wansmer/treesj", enabled = false },
-- System
{ "nvim-treesitter/nvim-treesitter-textobjects", enabled = false },
-- Disable Dap
{ "mfussenegger/nvim-dap", enabled = false },
{ "theHamsta/nvim-dap-virtual-text", enabled = false },
{ "rcarriga/nvim-dap-ui", enabled = false },
{ "jay-babu/mason-nvim-dap.nvim", enabled = false },
-- { "jay-babu/mason-null-ls.nvim", enabled = false },
{ "b0o/schemastore.nvim", enabled = false },
{ "Wansmer/treesj", enabled = false },
-- interface
-- { "HiPhish/rainbow-delimiters.nvim", enabled = true },
{ "ribru17/bamboo.nvim", enabled = true },
-- interface
{ "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 },
{ "github/copilot.vim", 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 },
{ "github/copilot.vim", enabled = true },
{ "rafamadriz/friendly-snippets", enabled = false },
{ "JoosepAlviste/nvim-ts-context-commentstring", enabled = false },
{ "windwp/nvim-ts-autotag", enabled = false },
{ "saadparwaiz1/cmp_luasnip", enabled = false },
{ "L3MON4D3/LuaSnip", enabled = true },
{ "rafamadriz/friendly-snippets", enabled = false },
{ "JoosepAlviste/nvim-ts-context-commentstring", enabled = false },
{ "windwp/nvim-ts-autotag", enabled = false },
{ "saadparwaiz1/cmp_luasnip", enabled = false },
{ "L3MON4D3/LuaSnip", enabled = true },
}
-- if true then return {} end

View File

@@ -205,49 +205,55 @@ return {
mode = { "n" },
desc = "Move to below split",
},
-- {
-- "<A-Left>",
-- function() require("smart-splits").resize_left() end,
-- mode = { "n" },
-- desc = "Resize split left",
-- },
-- {
-- "<A-Right>",
-- function() require("smart-splits").resize_right() end,
-- mode = { "n" },
-- desc = "Resize split right",
-- },
-- {
-- "<A-Up>",
-- function() require("smart-splits").resize_up() end,
-- mode = { "n" },
-- desc = "Resize split up",
-- },
-- {
-- "<A-Down>",
-- function() require("smart-splits").resize_down() end,
-- mode = { "n" },
-- desc = "Resize split down",
-- },
{
"<A-Left>",
"<S-h>",
function() require("smart-splits").resize_left() end,
mode = { "n" },
desc = "Resize split left",
},
{
"<A-Right>",
"<S-l>",
function() require("smart-splits").resize_right() end,
mode = { "n" },
desc = "Resize split right",
},
{
"<A-Up>",
function() require("smart-splits").resize_up() end,
mode = { "n" },
desc = "Resize split up",
},
{
"<A-Down>",
function() require("smart-splits").resize_down() end,
mode = { "n" },
desc = "Resize split down",
},
-- {
-- "<S-k>",
-- function() require("smart-splits").resize_up() end,
-- mode = { "n" },
-- desc = "Resize split up",
-- },
-- {
-- "<S-j>",
-- function() require("smart-splits").resize_down() end,
-- mode = { "n" },
-- desc = "Resize split down",
-- },
},
},
-- -- Find and replace
-- {
-- "MagicDuck/grug-far.nvim",
-- cmd = "GrugFar",
-- config = function()
-- require("grug-far").setup {
-- windowCreationCommand = "tabnew",
-- }
-- end,
-- keys = {
-- {
-- "<Leader>R",
-- function() require("grug-far").grug_far { prefills = { search = vim.fn.expand "<cword>" } } end,
-- mode = { "n" },
-- desc = "Open GrugFar",
-- },
-- },
-- },
-- Markdown preview support
}

View File

@@ -10,8 +10,8 @@ return {
-- 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, {
"lua_ls",
-- "jedi_language_server",
-- "ruff",
"jedi_language_server",
"ruff",
"basedpyright",
-- NOTE: "ty" is not a valid server name, so use masoninstall to install the server
})

View File

@@ -1,4 +1,3 @@
-- NOTE: always show hidden files and dot files
return {
"nvim-neo-tree/neo-tree.nvim",
opts = {
@@ -9,23 +8,23 @@ return {
filtered_items = {
visible = true,
show_hidden_count = true,
hide_dotfiles = true,
hide_gitignored = true,
hide_by_name = {
-- '.zip',
-- '.rar',
-- '.pdf',
-- '.DS_Store',
-- 'thumbs.db',
},
hide_dotfiles = false, -- always show dotfiles
hide_gitignored = false, -- always show gitignored
hide_by_name = {},
never_show = {},
never_show_by_pattern = { -- uses glob style patterns
"*.zip",
"*.rar",
"*.pdf",
-- "*.pdf",
},
},
},
window = {
mappings = {
["K"] = false, -- disable Shift+k
["H"] = false, -- disable Shift+k
},
},
enable_git_status = false,
enable_diagnostics = false,
git_status_async = false,

View File

@@ -1,7 +1,7 @@
return {
"folke/noice.nvim",
event = "VeryLazy",
dependencies = { "MunifTanjim/nui.nvim"},
dependencies = { "MunifTanjim/nui.nvim" },
config = function()
require("noice").setup({
-- Configuration here, or leave empty to use defaults
@@ -14,9 +14,9 @@ return {
},
lsp = {
override = {
["vim.lsp.util.convert_input_to_markdown_lines"] = false,
["vim.lsp.util.stylize_markdown"] = false,
["cmp.entry.get_documentation"] = false,
["vim.lsp.util.convert_input_to_markdown_lines"] = true,
["vim.lsp.util.stylize_markdown"] = true,
["cmp.entry.get_documentation"] = true,
},
progress = {
enabled = true,
@@ -24,7 +24,7 @@ return {
hover = {
enabled = true,
silent = true,
view = "hover",
view = nil,
opts = {
border = {
style = "rounded",
@@ -34,6 +34,9 @@ return {
wrap = true,
linebreak = true,
},
buf_options = {
filetype = "markdown",
},
},
},
signature = {
@@ -43,13 +46,14 @@ return {
enabled = false,
},
},
markdown = {},
presets = {
bottom_search = false, -- use a classic bottom cmdline for search
command_palette = true, -- position the cmdline and popupmenu together
long_message_to_split = false, -- long messages will be sent to a split
inc_rename = false, -- enables an input dialog for inc-rename.nvim
lsp_doc_border = false, -- add a border to hover docs and signature help
bottom_search = false, -- use a classic bottom cmdline for search
command_palette = true, -- position the cmdline and popupmenu together
long_message_to_split = true, -- long messages will be sent to a split
inc_rename = false, -- enables an input dialog for inc-rename.nvim
lsp_doc_border = false, -- add a border to hover docs and signature help
},
routes = {

View File

@@ -11,12 +11,10 @@ return {
-- config variable is the default configuration table for the setup function call
local null_ls = require("null-ls")
-- Check supported formatters and linters
-- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/formatting
-- https://github.com/nvimtools/none-ls.nvim/tree/main/lua/null-ls/builtins/diagnostics
opts.sources = {
require("none-ls.formatting.ruff").with({ extra_args = { "--extend-select", "F" } }),
require("none-ls.formatting.ruff_format"), -- Set a formatter
}
return opts
end,

View File

@@ -2,33 +2,32 @@
---@type LazySpec
return {
{
"nvim-treesitter/nvim-treesitter",
dependencies = {},
opts = function(_, opts)
-- add more things to the ensure_installed table protecting against community packs modifying it
opts.ignore_install = { "help" }
opts.ensure_installed = require("astrocore").list_insert_unique(opts.ensure_installed, {
-- "lua",
-- "c",
-- "cpp",
"python",
"latex",
"bibtex",
-- "javascript",
})
{
"nvim-treesitter/nvim-treesitter",
dependencies = {},
opts = function(_, opts)
-- add more things to the ensure_installed table protecting against community packs modifying it
opts.ignore_install = { "help" }
opts.ensure_installed = require("astrocore").list_insert_unique(opts.ensure_installed, {
-- "lua",
-- "c",
-- "cpp",
"python",
"latex",
-- "javascript",
})
opts.highlight = {
enable = true,
disable = { "c", "rust", "tsx", "javascript" },
additional_vim_regex_highlighting = false,
custom_captures = {
-- Highlight local variables
["variable.local"] = "Identifier",
},
}
opts.highlight = {
enable = true,
disable = { "c", "rust", "tsx", "javascript" },
additional_vim_regex_highlighting = false,
custom_captures = {
-- Highlight local variables
["variable.local"] = "Identifier",
},
}
vim.api.nvim_set_hl(0, "Identifier", { fg = "#55ffff" })
end,
},
vim.api.nvim_set_hl(0, "Identifier", { fg = "#55ffff" })
end,
},
}