I started using spacemacs today in combination with emacs mac port and noticed a very odd pasting behavior which seems like a bug (or misconfiguration on my end) to me.
v i "
I tried this many times in different files and also added the osx config layer but the behavior is always the same: When I paste in normal mode, the system clipboard gets pasted. When I paste in visual mode, the last register gets pasted and the system clipboard ignored.
Sadly this is the only way of replacing something with a system clipboard entry. d i w will remove the word and add it into the register so using p will only print the just deleted word
d i w
Am I doing something wrong?
Evil calls a different command called evil-visual-paste in this case so this might be a evil bug
Debugged a bit further and seems to be a problem with the GUI interface. When running on the terminal, pasting works fine. Both versions, normal emacs with cocoa and emacs mac port seem to have the problem mentioned above.
Tested with a different config file and the same problem persists so this is not a problem of spacemacs. I'm closing this issue, sorry for the mixup.
@dvcrn have you found a solution to this? It would still be helpful to people like me who found this issue in spacemacs(even if it isn't spacemacs related).
@voltecrus I did! It took a looooong time but eventually ran into this guys answer http://emacs.stackexchange.com/questions/14940/emacs-doesnt-paste-in-evils-visual-mode-with-every-os-clipboard/15054#15054
100% this should be the default!
(fset 'evil-visual-update-x-selection 'ignore)
This has been a real pain for me. I had no idea it was an issue with evil. As of today pasting to/from emacs works as it should. Thanks a lot @dvcrn for the solution!
I've had recurring problems with copying & pasting from/to spacemacs, where I'd try to copy something out and just end up with a single character, or paste something in and it would use an older yankring entry. @justin808's setting seems to have magically fixed all that.
... I spoke too soon. I had several blissful days of problem-free copy & pasting, and it's just cropped up again. Seems like there's something more complicated going on.