Python not working in nvim..
This commit is contained in:
parent
47687fca40
commit
74b4479f46
194
init.lua
194
init.lua
|
|
@ -277,7 +277,10 @@ require('lazy').setup({
|
||||||
version = '*',
|
version = '*',
|
||||||
lazy = false,
|
lazy = false,
|
||||||
config = function()
|
config = function()
|
||||||
require('nvim-tree').setup {}
|
require('nvim-tree').setup {
|
||||||
|
sync_root_with_cwd = true,
|
||||||
|
respect_buf_cwd = true,
|
||||||
|
}
|
||||||
-- Optional: Keybinding to toggle nvim-tree
|
-- Optional: Keybinding to toggle nvim-tree
|
||||||
vim.keymap.set('n', '<leader>e', ':NvimTreeToggle<CR>', { desc = 'Toggle File Explorer (nvim-tree)' })
|
vim.keymap.set('n', '<leader>e', ':NvimTreeToggle<CR>', { desc = 'Toggle File Explorer (nvim-tree)' })
|
||||||
end,
|
end,
|
||||||
|
|
@ -321,7 +324,17 @@ require('lazy').setup({
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
-- NOTE: CLaude code Plugin
|
||||||
|
|
||||||
|
{
|
||||||
|
'greggh/claude-code.nvim',
|
||||||
|
dependencies = {
|
||||||
|
'nvim-lua/plenary.nvim', -- Required for git operations
|
||||||
|
},
|
||||||
|
config = function()
|
||||||
|
require('claude-code').setup()
|
||||||
|
end,
|
||||||
|
},
|
||||||
-- NOTE: Plugins can also be configured to run Lua code when they are loaded.
|
-- NOTE: Plugins can also be configured to run Lua code when they are loaded.
|
||||||
--
|
--
|
||||||
-- This is often very useful to both group configuration, as well as handle
|
-- This is often very useful to both group configuration, as well as handle
|
||||||
|
|
@ -335,7 +348,6 @@ require('lazy').setup({
|
||||||
--
|
--
|
||||||
-- Then, because we use the `opts` key (recommended), the configuration runs
|
-- Then, because we use the `opts` key (recommended), the configuration runs
|
||||||
-- after the plugin has been loaded as `require(MODULE).setup(opts)`.
|
-- after the plugin has been loaded as `require(MODULE).setup(opts)`.
|
||||||
|
|
||||||
{ -- Useful plugin to show you pending keybinds.
|
{ -- Useful plugin to show you pending keybinds.
|
||||||
'folke/which-key.nvim',
|
'folke/which-key.nvim',
|
||||||
event = 'VimEnter', -- Sets the loading event to 'VimEnter'
|
event = 'VimEnter', -- Sets the loading event to 'VimEnter'
|
||||||
|
|
@ -388,73 +400,6 @@ require('lazy').setup({
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
--NOTE: Avante blink cmp
|
|
||||||
{
|
|
||||||
'Kaiser-Yang/blink-cmp-avante',
|
|
||||||
dependencies = { 'saghen/blink.cmp', 'yetone/avante.nvim' },
|
|
||||||
lazy = false,
|
|
||||||
},
|
|
||||||
--NOTE: Avante! Setup
|
|
||||||
|
|
||||||
{
|
|
||||||
'yetone/avante.nvim',
|
|
||||||
event = 'VeryLazy',
|
|
||||||
version = false, -- Never set this value to "*"! Never!
|
|
||||||
opts = {
|
|
||||||
-- add any opts here
|
|
||||||
-- for example
|
|
||||||
provider = 'claude',
|
|
||||||
openai = {
|
|
||||||
endpoint = 'https://api.anthropic.com',
|
|
||||||
model = 'claude-3-7-sonnet-20250219', -- your desired model (or use gpt-4o, etc.)
|
|
||||||
timeout = 30000, -- Timeout in milliseconds, increase this for reasoning models
|
|
||||||
temperature = 0,
|
|
||||||
max_completion_tokens = 8192, -- Increase this to include reasoning tokens (for reasoning models)
|
|
||||||
--reasoning_effort = "medium", -- low|medium|high, only used for reasoning models
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- if you want to build from source then do `make BUILD_FROM_SOURCE=true`
|
|
||||||
build = 'make',
|
|
||||||
-- build = "powershell -ExecutionPolicy Bypass -File Build.ps1 -BuildFromSource false" -- for windows
|
|
||||||
dependencies = {
|
|
||||||
'nvim-treesitter/nvim-treesitter',
|
|
||||||
'stevearc/dressing.nvim',
|
|
||||||
'nvim-lua/plenary.nvim',
|
|
||||||
'MunifTanjim/nui.nvim',
|
|
||||||
--- The below dependencies are optional,
|
|
||||||
'echasnovski/mini.pick', -- for file_selector provider mini.pick
|
|
||||||
'nvim-telescope/telescope.nvim', -- for file_selector provider telescope
|
|
||||||
'hrsh7th/nvim-cmp', -- autocompletion for avante commands and mentions
|
|
||||||
'ibhagwan/fzf-lua', -- for file_selector provider fzf
|
|
||||||
'nvim-tree/nvim-web-devicons', -- or echasnovski/mini.icons
|
|
||||||
'zbirenbaum/copilot.lua', -- for providers='copilot'
|
|
||||||
{
|
|
||||||
-- support for image pasting
|
|
||||||
'HakonHarnes/img-clip.nvim',
|
|
||||||
event = 'VeryLazy',
|
|
||||||
opts = {
|
|
||||||
-- recommended settings
|
|
||||||
default = {
|
|
||||||
embed_image_as_base64 = false,
|
|
||||||
prompt_for_file_name = false,
|
|
||||||
drag_and_drop = {
|
|
||||||
insert_mode = true,
|
|
||||||
},
|
|
||||||
-- required for Windows users
|
|
||||||
use_absolute_path = true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
-- Make sure to set this up properly if you have lazy=true
|
|
||||||
'MeanderingProgrammer/render-markdown.nvim',
|
|
||||||
opts = {
|
|
||||||
file_types = { 'markdown', 'Avante' },
|
|
||||||
},
|
|
||||||
ft = { 'markdown', 'Avante' },
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
-- NOTE: Plugins can specify dependencies.
|
-- NOTE: Plugins can specify dependencies.
|
||||||
--
|
--
|
||||||
-- The dependencies are proper plugin specifications as well - anything
|
-- The dependencies are proper plugin specifications as well - anything
|
||||||
|
|
@ -886,10 +831,6 @@ require('lazy').setup({
|
||||||
event = 'VimEnter',
|
event = 'VimEnter',
|
||||||
version = '1.*',
|
version = '1.*',
|
||||||
dependencies = {
|
dependencies = {
|
||||||
--
|
|
||||||
--
|
|
||||||
--
|
|
||||||
'Kaiser-Yang/blink-cmp-avante',
|
|
||||||
-- Snippet Engine
|
-- Snippet Engine
|
||||||
{
|
{
|
||||||
'L3MON4D3/LuaSnip',
|
'L3MON4D3/LuaSnip',
|
||||||
|
|
@ -907,12 +848,12 @@ require('lazy').setup({
|
||||||
-- `friendly-snippets` contains a variety of premade snippets.
|
-- `friendly-snippets` contains a variety of premade snippets.
|
||||||
-- See the README about individual language/framework/plugin snippets:
|
-- See the README about individual language/framework/plugin snippets:
|
||||||
-- https://github.com/rafamadriz/friendly-snippets
|
-- https://github.com/rafamadriz/friendly-snippets
|
||||||
-- {
|
{
|
||||||
-- 'rafamadriz/friendly-snippets',
|
'rafamadriz/friendly-snippets',
|
||||||
-- config = function()
|
config = function()
|
||||||
-- require('luasnip.loaders.from_vscode').lazy_load()
|
require('luasnip.loaders.from_vscode').lazy_load()
|
||||||
-- end,
|
end,
|
||||||
-- },
|
},
|
||||||
},
|
},
|
||||||
opts = {},
|
opts = {},
|
||||||
},
|
},
|
||||||
|
|
@ -961,56 +902,13 @@ require('lazy').setup({
|
||||||
documentation = { auto_show = false, auto_show_delay_ms = 500 },
|
documentation = { auto_show = false, auto_show_delay_ms = 500 },
|
||||||
},
|
},
|
||||||
|
|
||||||
-- providers = {
|
|
||||||
-- lazydev = { module = 'lazydev.integrations.blink', score_offset = 100 },
|
|
||||||
-- avante_commands = {
|
|
||||||
-- name = 'avante_commands',
|
|
||||||
-- module = 'blink.compat.source',
|
|
||||||
-- score_offset = 90,
|
|
||||||
-- opts = {},
|
|
||||||
-- },
|
|
||||||
-- avante_files = {
|
|
||||||
-- name = 'avante_files',
|
|
||||||
-- module = 'blink.compat.source',
|
|
||||||
-- score_offset = 100,
|
|
||||||
-- opts = {},
|
|
||||||
-- },
|
|
||||||
-- avante_mentions = {
|
|
||||||
-- name = 'avante_mentions',
|
|
||||||
-- module = 'blink.compat.source',
|
|
||||||
-- score_offset = 1000,
|
|
||||||
-- opts = {},
|
|
||||||
-- },
|
|
||||||
-- },
|
|
||||||
-- },
|
|
||||||
--
|
|
||||||
sources = {
|
sources = {
|
||||||
default = { 'avante', 'lsp', 'path', 'snippets', 'lazydev' },
|
default = { 'lsp', 'path', 'snippets', 'lazydev' },
|
||||||
providers = {
|
providers = {
|
||||||
lazydev = {
|
lazydev = {
|
||||||
module = 'lazydev.integrations.blink',
|
module = 'lazydev.integrations.blink',
|
||||||
score_offset = 100,
|
score_offset = 100,
|
||||||
},
|
},
|
||||||
avante = {
|
|
||||||
name = 'Avante',
|
|
||||||
module = 'blink-cmp-avante',
|
|
||||||
opts = {
|
|
||||||
command = {
|
|
||||||
get_kind_name = function()
|
|
||||||
return 'AvanteCmd'
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
mention = {
|
|
||||||
get_kind_name = function()
|
|
||||||
return 'AvanteMention'
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
kind_icons = {
|
|
||||||
AvanteCmd = '',
|
|
||||||
AvanteMention = '',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
snippets = { preset = 'luasnip' },
|
snippets = { preset = 'luasnip' },
|
||||||
|
|
@ -1194,8 +1092,54 @@ require('lazy').setup({
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
})
|
})
|
||||||
-- vim.api.nvim_set_hl(0, 'BlinkCmpKindAvanteCmd', { default = false, fg = '#89b4fa' })
|
|
||||||
-- vim.api.nvim_set_hl(0, 'BlinkCmpKindAvanteMention', { default = false, fg = '#f38ba8' })
|
-- NOTE: Claude Code Plugin Config
|
||||||
|
require('claude-code').setup {
|
||||||
|
-- Terminal window settings
|
||||||
|
window = {
|
||||||
|
split_ratio = 0.3, -- Percentage of screen for the terminal window (height for horizontal, width for vertical splits)
|
||||||
|
position = 'vertical', -- Position of the window: "botright", "topleft", "vertical", "rightbelow vsplit", etc.
|
||||||
|
enter_insert = true, -- Whether to enter insert mode when opening Claude Code
|
||||||
|
hide_numbers = true, -- Hide line numbers in the terminal window
|
||||||
|
hide_signcolumn = true, -- Hide the sign column in the terminal window
|
||||||
|
},
|
||||||
|
-- File refresh settings
|
||||||
|
refresh = {
|
||||||
|
enable = true, -- Enable file change detection
|
||||||
|
updatetime = 100, -- updatetime when Claude Code is active (milliseconds)
|
||||||
|
timer_interval = 1000, -- How often to check for file changes (milliseconds)
|
||||||
|
show_notifications = true, -- Show notification when files are reloaded
|
||||||
|
},
|
||||||
|
-- Git project settings
|
||||||
|
git = {
|
||||||
|
use_git_root = true, -- Set CWD to git root when opening Claude Code (if in git project)
|
||||||
|
},
|
||||||
|
-- Command settings
|
||||||
|
command = 'claude', -- Command used to launch Claude Code
|
||||||
|
-- Command variants
|
||||||
|
command_variants = {
|
||||||
|
-- Conversation management
|
||||||
|
continue = '--continue', -- Resume the most recent conversation
|
||||||
|
resume = '--resume', -- Display an interactive conversation picker
|
||||||
|
|
||||||
|
-- Output options
|
||||||
|
verbose = '--verbose', -- Enable verbose logging with full turn-by-turn output
|
||||||
|
},
|
||||||
|
-- Keymaps
|
||||||
|
keymaps = {
|
||||||
|
toggle = {
|
||||||
|
normal = '<C-,>', -- Normal mode keymap for toggling Claude Code, false to disable
|
||||||
|
terminal = '<C-,>', -- Terminal mode keymap for toggling Claude Code, false to disable
|
||||||
|
variants = {
|
||||||
|
continue = '<leader>cC', -- Normal mode keymap for Claude Code with continue flag
|
||||||
|
verbose = '<leader>cV', -- Normal mode keymap for Claude Code with verbose flag
|
||||||
|
},
|
||||||
|
},
|
||||||
|
window_navigation = true, -- Enable window navigation keymaps (<C-h/j/k/l>)
|
||||||
|
scrolling = true, -- Enable scrolling keymaps (<C-f/b>) for page up/down
|
||||||
|
},
|
||||||
|
}
|
||||||
|
|
||||||
-- The line beneath this is called `modeline`. See `:help modeline`
|
-- The line beneath this is called `modeline`. See `:help modeline`
|
||||||
-- vim: ts=2 sts=2 sw=2 et
|
-- vim: ts=2 sts=2 sw=2 et
|
||||||
|
vim.g.python3_host_prog = '/Users/fq/.pyenv/versions/3.13.1/envs/rca/bin/python3'
|
||||||
|
|
|
||||||
|
|
@ -1,31 +1,23 @@
|
||||||
{
|
{
|
||||||
"LuaSnip": { "branch": "master", "commit": "03c8e67eb7293c404845b3982db895d59c0d1538" },
|
"LuaSnip": { "branch": "master", "commit": "458560534a73f7f8d7a11a146c801db00b081df0" },
|
||||||
"avante.nvim": { "branch": "main", "commit": "b2064a8f40cbd10ddd3ea9d82f0bdb2bcaf2f152" },
|
|
||||||
"blink-cmp-avante": { "branch": "master", "commit": "ddefb8de3cb1286ab39e0ccec0f32a45d03391f2" },
|
|
||||||
"blink.cmp": { "branch": "main", "commit": "4f38ce99a472932d5776337f08f7a8180f1f571a" },
|
"blink.cmp": { "branch": "main", "commit": "4f38ce99a472932d5776337f08f7a8180f1f571a" },
|
||||||
"conform.nvim": { "branch": "master", "commit": "372fc521f8421b7830ea6db4d6ea3bae1c77548c" },
|
"claude-code.nvim": { "branch": "main", "commit": "ffdf35d8566528cb144d9812eccfecee34502edf" },
|
||||||
"copilot.lua": { "branch": "master", "commit": "7ba73866b9b3c696f80579c470c6eec374d3acec" },
|
"conform.nvim": { "branch": "master", "commit": "374aaf384e2e841607b8e2fe63fa3ad01d111c91" },
|
||||||
"dressing.nvim": { "branch": "master", "commit": "2d7c2db2507fa3c4956142ee607431ddb2828639" },
|
|
||||||
"fidget.nvim": { "branch": "main", "commit": "d9ba6b7bfe29b3119a610892af67602641da778e" },
|
"fidget.nvim": { "branch": "main", "commit": "d9ba6b7bfe29b3119a610892af67602641da778e" },
|
||||||
"fzf-lua": { "branch": "main", "commit": "02def6b972d7687866738d6f6a5f4839ce5b5a7a" },
|
"friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" },
|
||||||
"gitsigns.nvim": { "branch": "main", "commit": "43b0c856ae5f32a195d83f4a27fe21d63e6c966c" },
|
"gitsigns.nvim": { "branch": "main", "commit": "43b0c856ae5f32a195d83f4a27fe21d63e6c966c" },
|
||||||
"img-clip.nvim": { "branch": "main", "commit": "08a02e14c8c0d42fa7a92c30a98fd04d6993b35d" },
|
|
||||||
"kanso.nvim": { "branch": "main", "commit": "62e9c5d669567d086474b2b6863e0724c71c6c99" },
|
"kanso.nvim": { "branch": "main", "commit": "62e9c5d669567d086474b2b6863e0724c71c6c99" },
|
||||||
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
|
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
|
||||||
"lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" },
|
"lazydev.nvim": { "branch": "main", "commit": "2367a6c0a01eb9edb0464731cc0fb61ed9ab9d2c" },
|
||||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "d39a75bbce4b8aad5d627191ea915179c77c100f" },
|
"mason-lspconfig.nvim": { "branch": "main", "commit": "d39a75bbce4b8aad5d627191ea915179c77c100f" },
|
||||||
"mason-tool-installer.nvim": { "branch": "main", "commit": "aafae207d5a2a28c59c9d478d8581c2739135d09" },
|
"mason-tool-installer.nvim": { "branch": "main", "commit": "aafae207d5a2a28c59c9d478d8581c2739135d09" },
|
||||||
"mason.nvim": { "branch": "main", "commit": "7c7318e8bae7e3536ef6b9e86b9e38e74f2e125e" },
|
"mason.nvim": { "branch": "main", "commit": "7c7318e8bae7e3536ef6b9e86b9e38e74f2e125e" },
|
||||||
"mini.nvim": { "branch": "main", "commit": "6105b69d79fef0afed5ed576081b1997ef2b4be1" },
|
"mini.nvim": { "branch": "main", "commit": "a9e4cb303ea6269ecab92c0276baf9d04370c492" },
|
||||||
"mini.pick": { "branch": "main", "commit": "fa1e449e1080bf7aa9b2890ee186d23b1b4e1287" },
|
"nvim-lspconfig": { "branch": "master", "commit": "f817582301b2c188c1cff7c956971ce3f85631ff" },
|
||||||
"nui.nvim": { "branch": "main", "commit": "f535005e6ad1016383f24e39559833759453564e" },
|
|
||||||
"nvim-cmp": { "branch": "main", "commit": "b5311ab3ed9c846b585c0c15b7559be131ec4be9" },
|
|
||||||
"nvim-lspconfig": { "branch": "master", "commit": "4bc481b6f0c0cf3671fc894debd0e00347089a4e" },
|
|
||||||
"nvim-tree.lua": { "branch": "master", "commit": "be5b788f2dc1522c73fb7afad9092331c8aebe80" },
|
"nvim-tree.lua": { "branch": "master", "commit": "be5b788f2dc1522c73fb7afad9092331c8aebe80" },
|
||||||
"nvim-treesitter": { "branch": "master", "commit": "28d480e0624b259095e56f353ec911f9f2a0f404" },
|
"nvim-treesitter": { "branch": "master", "commit": "28d480e0624b259095e56f353ec911f9f2a0f404" },
|
||||||
"nvim-web-devicons": { "branch": "master", "commit": "2c2b4eafce6cdd0cb165036faa17396eff18f847" },
|
"nvim-web-devicons": { "branch": "master", "commit": "f1420728f59843eb2ef084406b3d0201a0a0932d" },
|
||||||
"plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" },
|
"plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" },
|
||||||
"render-markdown.nvim": { "branch": "main", "commit": "ff577b44bd3ab642acec0f134a7bf26b7278d137" },
|
|
||||||
"telescope-fzf-native.nvim": { "branch": "main", "commit": "1f08ed60cafc8f6168b72b80be2b2ea149813e55" },
|
"telescope-fzf-native.nvim": { "branch": "main", "commit": "1f08ed60cafc8f6168b72b80be2b2ea149813e55" },
|
||||||
"telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" },
|
"telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" },
|
||||||
"telescope.nvim": { "branch": "master", "commit": "a4ed82509cecc56df1c7138920a1aeaf246c0ac5" },
|
"telescope.nvim": { "branch": "master", "commit": "a4ed82509cecc56df1c7138920a1aeaf246c0ac5" },
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue