neovim-e
neovim-e copied to clipboard
Paste not working in OSX
I'm not sure about other OS's, but paste isn't working in any capacity for me. I believe it's just a no-op because of the default menu.
Regardless of the default menu, <D-v> is sent to neovim, but neovim doesn't handle <D-...> mappings it seems because doing nmap <D-v> hi
and then map <
shows that it's registering it as individual keystrokes and not one key combination.
I can add a handler to respond to cmd-v
from the menu, but I'm not sure how paste is implemented in neovim, and I would like to do it the official way if there is a msgpack endpoint.
neovim uses pbcopy
and pbpaste
http://neovim.org/doc/user/nvim_clipboard.html
@coolwanglu @norcalli Will we then be able to have it easily? Is there still work to be done?
I implemented it on my branch, but I think mine is outdated now. I did it the way neovim did it which is to use
Thank you,Ashkan Kiani
On Sat, May 9, 2015 at 1:04 AM, Giovanni [email protected] wrote:
@coolwanglu @norcalli Will we then be able to have it easily? Is there still work to be done?
Reply to this email directly or view it on GitHub: https://github.com/coolwanglu/neovim-e/issues/29#issuecomment-100445169
Did you set :set paste
?
Sorry I was going to sleep last night. On the paste trigger, I do @ui.emit "input", "<f37>#{text}<f36>"
and previously I defined
@command 'inoremap <f37> <f36>'
@command 'nnoremap <f37> <f36>o'
@command 'set pastetoggle=<f36>'
where @command
is just a @session.request "vim_command", [cmd], (err, resp) =>
.
This should make it so that the paste command triggered inserts the text in each mode. Obviously I chose the behaviour of it pasting on a new line and choosing to stay in insert mode.
When I go to insert mode then run cmd v
I get my pasted text wrapped in <F37>
However when I run "+p
I get the correct pasted text.
This is a nvim
bug, not neovim-e
.