From 3380197bab09db7618ce127986ea0a590333496c Mon Sep 17 00:00:00 2001 From: Prad Nukala Date: Tue, 25 Aug 2026 14:47:08 -0400 Subject: [PATCH] feat(core): add python community packs and UI toggle setup --- lua/community.lua | 6 ++++++ lua/polish.lua | 19 ++++--------------- 2 files changed, 10 insertions(+), 15 deletions(-) diff --git a/lua/community.lua b/lua/community.lua index b198b00..4929e8d 100644 --- a/lua/community.lua +++ b/lua/community.lua @@ -24,6 +24,12 @@ return { { import = "astrocommunity.pack.toml" }, { import = "astrocommunity.pack.typescript" }, { import = "astrocommunity.pack.tailwindcss" }, + -- python: treesitter/debugpy/venv-selector + basedpyright language server. + -- The full `pack.python` also pulls black + isort; formatting stays on ruff + -- (see plugins/conform.lua), so only the base and basedpyright subpacks are + -- imported. Interpreter resolution is overridden in plugins/python.lua. + { import = "astrocommunity.pack.python.base" }, + { import = "astrocommunity.pack.python.basedpyright" }, { import = "astrocommunity.completion.supermaven-nvim" }, { import = "astrocommunity.lsp.dev-tools-nvim" }, { import = "astrocommunity.lsp.lsp-signature-nvim" }, diff --git a/lua/polish.lua b/lua/polish.lua index ef09175..69009a2 100644 --- a/lua/polish.lua +++ b/lua/polish.lua @@ -1,18 +1,7 @@ -- This will run last in the setup process. -- Pure lua; anything that doesn't fit the normal config locations goes here. --- Snacks.keymap: LSP-aware keymaps, only applied to buffers with a client --- that supports the given method (which-key picks up the desc). ]] and [[ --- cycle through the LSP references that snacks.words auto-highlights, --- complementing the core astrolsp `gd` / `gr` binds. -local ok, snacks = pcall(require, "snacks") -if ok then - snacks.keymap.set("n", "]]", function() snacks.words.jump(vim.v.count1, true) end, { - lsp = { method = "textDocument/documentHighlight" }, - desc = "Next reference", - }) - snacks.keymap.set("n", "[[", function() snacks.words.jump(-vim.v.count1, true) end, { - lsp = { method = "textDocument/documentHighlight" }, - desc = "Previous reference", - }) -end +-- u UI toggles, mapped via Snacks.toggle so which-key shows the +-- snacks state icons/colors (see config.toggles). LSP-scoped keymaps live in +-- plugins/astrolsp.lua, where astrolsp gates them on server capabilities. +require("config.toggles").setup()