zsh-autosuggestions icon indicating copy to clipboard operation
zsh-autosuggestions copied to clipboard

conflict with syntax-highlighting plug

Open day0n opened this issue 3 years ago • 12 comments

Describe the bug

Screenshots

Desktop

  • mac OS
  • oh my zsh
  • Plugin version

Additional context

this doesn't work when I use syntax-highlight plug.

day0n avatar Mar 23 '22 02:03 day0n

I have the same issue:

  • macOS Monterrey 12.4

  • iTerm2 3.4.15

  • zsh 5.8.1

  • oh-my-zsh

  • Plugin versions:

    • zsh-autosuggestions: v0.6.4
    • zsh-syntax-highlighting: 0.8.0-alpha2-dev
  • Both plugins active plugins=(zsh-autosuggestions zsh-syntax-highlighting) Screen Shot 2022-05-24 at 21 01 02

  • Only autosuggestions active plugins=(zsh-autosuggestions) Screen Shot 2022-05-24 at 21 02 28

I'm also setting the color in my .zshrc file:

ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE="fg=242"

scrubmx avatar May 25 '22 02:05 scrubmx

I have the same issue

jimmyn avatar May 26 '22 09:05 jimmyn

Me too (on Alpine Linux, without OhMyZsh).

jirutka avatar May 26 '22 10:05 jirutka

Same here :/

pawel-omniaz avatar Jun 02 '22 06:06 pawel-omniaz

I have an identical problem, One thing though, if I connect to a server through ssh, highlight appears properly...

DimitriGilbert avatar Jun 07 '22 06:06 DimitriGilbert

I have the very same behaviour as described by @DimitriGilbert However, I observed this only after updating to Ubuntu 22.04. I wonder if there's a connection.

ih8ms avatar Jun 10 '22 09:06 ih8ms

I was able to fix the issue by updating both autosuggestions and syntax-highlighting to their latest versions from GitHub (just cloned the repos).

ih8ms avatar Jun 10 '22 09:06 ih8ms

Yep, I can confirm - updating both plugins fixed it for me too on Mac OS :) Thanks! I thought those plugins are updated automatically by Oh My Zsh or something ;)

pawel-omniaz avatar Jun 10 '22 09:06 pawel-omniaz

same thing, and just like @pawel-omniaz , I didn't even think I was in charge of the update.

DimitriGilbert avatar Jun 11 '22 07:06 DimitriGilbert

Had the same issue, removed plugins from ~/.oh-my-zsh/custom/plugins/ and then re-installed them via

Syntax highlighting

git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting

Autosuggestions

git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions

shotexa avatar Jun 12 '22 22:06 shotexa

this bug was driving me crazy and i was changing the autosuggest highlight style to so many different colours to test it out and i couldnt fix it properly until i followed @shotexa's instructions above. my main issue was i had no idea where my old plugins were being installed to so after reinstalling them it was still pointing to the old ones that weren't patched.

just in case others somehow have it installed in another directory similar to mine even when running the default git clone commands, this was my path i did rm -rf with to remove them completely and to activate the source for zsh-syntax-highlighting with at the end of your .zshrc file.

source /Users/CHANGE_THIS_WITH_YOUR_USER/.oh-my-zsh/custom/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh

findtravishere avatar Jun 14 '22 15:06 findtravishere

This problem persists on Zsh 5.8.1 even with the latest revision of both plugins but is no longer present on Zsh 5.9.

jirutka avatar Aug 06 '22 20:08 jirutka