Registered yanks not cycling
davejacobs opened this issue · comments
I haven't been able to get yankstack to cycle through registered yanks. Looks like everything is set up properly. This is what I've been doing to test:
-
Type:
First line
Second line
Third line -
Go to first line
-
Copy first, second and third lines with
yy
-
Inspect
:Yanks
output to make sure that all's well -
Paste the third line onto the fourth line using
p
-
Attempt to cycle backwards using
<M-p>
On my machine, I can't get the cycling to work. (<M-p>
looks like a no-op.)
Here's some debugging output:
:Yanks
:
0 Third line
1 Second line
2 First line
map <M-p>
:
yankstack_substitute_older_paste
When I enter insert mode then escape and hit <M-p>
, I get the right message: "Last change was not a paste." Any idea what's going on? (I cloned the HEAD of master yesterday.) Thanks!
Ok, so yanks are getting pushed onto the stack correctly, and meta-p is doing something. Maybe the p
key isn't getting remapped properly?
When you run map p
, you should see <Plug>yankstack_p
, and map P
should be <Plug>yankstack_P
. These mappings store some information that needed by yankstack before calling through to the normal paste keys. But also, you should still be able to remap p
and P
, as long as you call yankstack#setup()
first.
Maybe sometime at work I could try it on your machine. I haven't really tested yankstack with too many different setups yet. Thanks for trying it!
Per our coffee shop debugging session, removing set clipboard=unnamed
makes everything smooth as buttah. Sweet.
Adding an issue for compatibility with clipboard=unnamed