Skip to content

Commit 52b1207

Browse files
committed
adding b-changes
1 parent 5188bb0 commit 52b1207

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

lua/custom/keymaps.lua

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,3 +38,12 @@ end)
3838

3939
-- In your keybindings configuration (e.g., lua/config/keymaps.lua or init.lua)
4040
vim.keymap.set('n', '<leader>w', '<cmd>NvimTreeToggle<CR>', { desc = 'Toggle NvimTree' })
41+
42+
vim.keymap.set({ 'n', 't' }, '<leader>rr', function()
43+
local chan = vim.b.terminal_job_id
44+
if not chan then
45+
vim.notify('Not in a terminal buffer', vim.log.levels.ERROR)
46+
return
47+
end
48+
vim.api.nvim_chan_send(chan, 'source venv/bin/activate\n')
49+
end, { desc = 'Activating VENV virtual environment (if it exists LOL)' })

0 commit comments

Comments
 (0)