Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Suggestions not cleared on yank/yank-pop #526

Open
aaronjensen opened this issue Apr 19, 2020 · 3 comments
Open

Suggestions not cleared on yank/yank-pop #526

aaronjensen opened this issue Apr 19, 2020 · 3 comments
Labels

Comments

@aaronjensen
Copy link

aaronjensen commented Apr 19, 2020

Describe the bug

If an autosuggest is present, and you use C-y to yank (paste), the autosuggest is not cleared

To Reproduce

Steps to reproduce the behavior:

% zsh -df
% source path/to/zsh-autosuggestions.zsh
% ls bar
% ls foo # Then hit C-w followed by C-y

Expected behavior

There should be no autosuggest visible.

Screenshots

CleanShot 2020-04-19 at 08 31 56@2x

Desktop

  • OS + distribution: macOS 10.15.4
  • Zsh version: 5.8
  • Plugin version: 0.6.4, ae315de

Additional context

I saw zsh-users/zsh-syntax-highlighting#150

I tried

ZSH_AUTOSUGGEST_CLEAR_WIDGETS+=(yank yank-pop)

And that did not appear to help

@aaronjensen aaronjensen changed the title autosuggest not cleared on yank-pop Suggestions not cleared on yank-pop Apr 19, 2020
@sgleizes
Copy link

sgleizes commented May 8, 2020

This seems to be due to the defaults having yank and yank-pop in ZSH_AUTOSUGGEST_IGNORE_WIDGETS.

Removing them from there properly clears the suggestion, however it seems to break the behavior of yank-pop which is probably why it was there in the first place.

So IIUC for now you have to choose between clearing the suggestion on yank and using yank-pop.

@aaronjensen aaronjensen changed the title Suggestions not cleared on yank-pop Suggestions not cleared on yank/yank-pop May 9, 2020
@aaronjensen
Copy link
Author

@sgleizes Thanks, that's helpful. It'd be nice to be able to have my cake and yank-pop it too, however.

@vincentbernat
Copy link

This could be fixed by the patch proposed in #363.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants