romkatv / powerlevel10k

A Zsh theme
MIT License
46.37k stars 2.19k forks source link

vscode cannot trigger copilot prompt after oh-my-zsh uses p10k theme #2513

Open Syed-Wang opened 10 months ago

Syed-Wang commented 10 months ago

Snipaste_2023-12-20_11-37-19

romkatv commented 10 months ago

It might be the same thing as https://github.com/romkatv/powerlevel10k/issues/2480#issuecomment-1793676187

Please try that solution and let me know if it helps. If it does, it'll definitely need to change something in powerlevel10k to make this sort of thing automatic.

Syed-Wang commented 10 months ago

Snipaste_2023-12-21_15-05-51

Thanks, the dots can display normally, but it does not solve the problem about Copilot prompts.

romkatv commented 10 months ago

I've never used vscode copilot. Can you describe what exactly does not work?

Syed-Wang commented 10 months ago

copilot is an AI assistant, and the features I've described are provided by the GitHub Copilot Chat extension in vscode, which provides some suggestions via the vscode terminal.

I work in Ubuntu and use oh-my-zsh, copilot has no problem when using the built-in theme (I tried ZSH_THEME="random"). As you can see, when I click on the star, the suggestion is automatically given. Snipaste_2023-12-21_17-22-38

But with the powerlevel10k theme, there was no star button, so I couldn't use the GitHub Copilot Chat extension's quick suggestions for terminals. As shown in the figure. Snipaste_2023-12-21_17-35-14

romkatv commented 10 months ago

Thanks for the info. I'll try to reproduce this.

Syed-Wang commented 10 months ago

Excuse me. Is there a solution to this situation?

romkatv commented 10 months ago

I haven't done anything here yet. I'm not sure when I'll get around to it.

leozvoy commented 3 months ago

Same problem

image image
romkatv commented 3 months ago

See https://github.com/romkatv/powerlevel10k/issues/2480#issuecomment-1793676187

leozvoy commented 3 months ago

See #2480 (comment)

Thanks, but it didn't work for me. Probably this is an issue with vscode.

romkatv commented 3 months ago

I'm aware. It works with POWERLEVEL9K_TERM_SHELL_INTEGRATION=true for you, right?

leozvoy commented 3 months ago

I'm aware. It works with POWERLEVEL9K_TERM_SHELL_INTEGRATION=true for you, right?

I added POWERLEVEL9K_TERM_SHELL_INTEGRATION=true to ~/.p10k.zsh, but I didn't see any different.

My powerlevel10k works perfectly expect missing the copilot hint button in the vscode terminal.

romkatv commented 3 months ago

What is the output of the following command?

typeset -p _POWERLEVEL9K_TERM_SHELL_INTEGRATION
leozvoy commented 3 months ago

What is the output of the following command?

typeset -p _POWERLEVEL9K_TERM_SHELL_INTEGRATION

typeset -i _POWERLEVEL9K_TERM_SHELL_INTEGRATION=1

romkatv commented 3 months ago

Thanks for the additional info. The comment you've quoted says that POWERLEVEL9K_TERM_SHELL_INTEGRATION=true is enough to work around the problem, but for you it isn't. That's useful to know.

leozvoy commented 3 months ago

Thanks for the additional info. The comment you've quoted says that POWERLEVEL9K_TERM_SHELL_INTEGRATION=true is enough to work around the problem, but for you it isn't. That's useful to know.

It's not a big deal, PowerLevel10K is a lot better than other themes, and it would be perfect if this problem could be solved in the future😁