mirror of
https://github.com/dcarrillo/dotfiles.git
synced 2025-01-09 18:06:48 +00:00
[neovim] Add python goodies
This commit is contained in:
parent
81e4ec11d8
commit
64cf03dcac
@ -12,6 +12,7 @@ Neovim conf heavily adapted to suit my needs, formerly based on LunarVim's [basi
|
||||
* stylua
|
||||
* python-cfn-lint
|
||||
* python-black
|
||||
* python-debugpy
|
||||
* hadolint
|
||||
* revive
|
||||
* tree-sitter-cli
|
||||
|
@ -226,9 +226,20 @@ require("lazy").setup({
|
||||
-- DAP
|
||||
{ "mfussenegger/nvim-dap", event = "VeryLazy", version = "0.*" },
|
||||
{ "rcarriga/nvim-dap-ui", event = "VeryLazy", version = "v3.*" },
|
||||
{ "ravenxrz/DAPInstall.nvim", event = "VeryLazy" },
|
||||
{ "theHamsta/nvim-dap-virtual-text", event = "VeryLazy" },
|
||||
|
||||
-- Python
|
||||
{
|
||||
"linux-cultist/venv-selector.nvim",
|
||||
dependencies = {
|
||||
"mfussenegger/nvim-dap-python",
|
||||
},
|
||||
opts = {
|
||||
dap_enabled = true,
|
||||
},
|
||||
event = "VeryLazy",
|
||||
},
|
||||
|
||||
-- Go
|
||||
{
|
||||
"ray-x/go.nvim",
|
||||
@ -239,6 +250,8 @@ require("lazy").setup({
|
||||
event = { "CmdlineEnter" },
|
||||
ft = { "go", "gomod" },
|
||||
},
|
||||
|
||||
-- Testing
|
||||
{
|
||||
"nvim-neotest/neotest",
|
||||
dependencies = {
|
||||
|
@ -1,7 +1,9 @@
|
||||
local dap = require("dap")
|
||||
local dapui = require("dapui")
|
||||
|
||||
require("dap-install").config("python", {})
|
||||
local debugpyPythonPath = require("mason-registry").get_package("debugpy"):get_install_path() .. "/venv/bin/python3"
|
||||
require("dap-python").setup(debugpyPythonPath, {})
|
||||
|
||||
dapui.setup({
|
||||
layouts = {
|
||||
{
|
||||
|
@ -41,6 +41,11 @@ local venv = function()
|
||||
return string.format(" %s", string.match(venv, "[^/]+$"))
|
||||
end
|
||||
|
||||
venv = require("venv-selector").get_active_venv()
|
||||
if venv then
|
||||
return string.format(" %s", string.match(venv, "[^/]+$"))
|
||||
end
|
||||
|
||||
return ""
|
||||
end
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user