toggleterm.nvim icon indicating copy to clipboard operation
toggleterm.nvim copied to clipboard

[BUG] is there a way to paste in toggle term?

Open justrajdeep opened this issue 10 months ago • 0 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Current Behavior

Hi

I am using the suggested mapping

_G.set_terminal_keymaps = function ()
  local opts = {buffer = 0}
  vim.keymap.set('t', '<esc>', [[<C-\><C-n>]], opts)
  -- vim.keymap.set('t', 'jk', [[<C-\><C-n>]], opts)
  vim.keymap.set('t', '<C-h>', [[<Cmd>wincmd h<CR>]], opts)
  vim.keymap.set('t', '<C-j>', [[<Cmd>wincmd j<CR>]], opts)
  vim.keymap.set('t', '<C-k>', [[<Cmd>wincmd k<CR>]], opts)
  vim.keymap.set('t', '<C-l>', [[<Cmd>wincmd l<CR>]], opts)
  vim.keymap.set('t', '<C-w>', [[<C-\><C-n><C-w>]], opts)
end

-- if you only want these mappings for toggle term use term://*toggleterm#* instead
vim.cmd('autocmd! TermOpen term://* lua set_terminal_keymaps()')

i can press ESC and move around and copy stuff. But I am not able to paste stuff in the terminal

Is there a way to paste stuff in the terminal.

I looked though the issues and document but could not find anything.

TIA

Expected Behavior

Not sure.

Steps To Reproduce

using zsh in my terminal with fzf, C-r opens fzf command picker.

Environment

- OS:
LSB Version:	:core-4.1-amd64:core-4.1-noarch:cxx-4.1-amd64:cxx-4.1-noarch:desktop-4.1-amd64:desktop-4.1-noarch:languages-4.1-amd64:languages-4.1-noarch:printing-4.1-amd64:printing-4.1-noarch
Distributor ID:	CentOS
Description:	CentOS Linux release 7.5.1804 (Core) 
Release:	7.5.1804
Codename:	Core

- neovim version:
:Verbose :version

NVIM v0.10.0-dev-a89ce8974
Build type: RelWithDebInfo
LuaJIT 2.1.1710088188
Compilation: /home/rmondal/.local/bin/cc -O2 -g -Og -g -flto=auto -fno-fat-lto-objects -Wall -Wextra -pedantic -Wno-unused-parameter -Wstrict-prototypes -std=gnu99 -Wshadow -Wconversion -Wvla -Wdouble-promotion -Wmissing-noreturn -Wmissing-format-attribute -Wmissing-prototypes -fsigned-char -fstack-protector-strong -Wno-conversion -fno-common -Wno-unused-result -Wimplicit-fallthrough -fdiagnostics-color=always  -DUNIT_TESTING -DHAVE_UNIBILIUM -D_GNU_SOURCE -DINCLUDE_GENERATED_DECLARATIONS -I/home/scratch.rmondal_mobile/home/neovim/core_neovim/.deps/usr/include/luajit-2.1 -I/home/scratch.rmondal_mobile/home/neovim/core_neovim/.deps/usr/include -I/home/scratch.rmondal_mobile/home/neovim/core_neovim/build/src/nvim/auto -I/home/scratch.rmondal_mobile/home/neovim/core_neovim/build/include -I/home/scratch.rmondal_mobile/home/neovim/core_neovim/build/cmake.config -I/home/scratch.rmondal_mobile/home/neovim/core_neovim/src -I/usr/include 

   system vimrc file: "$VIM/sysinit.vim"
  fall-back for $VIM: "/home/rmondal/bin/share/nvim"

Run :checkhealth for more info


- Shell: zsh with zsh

Anything else?

No response

justrajdeep avatar Mar 28 '24 19:03 justrajdeep