我在MacOS蒙特利的Zsh上使用了PowerLevel10k。
现在我已经为MacOS安装了Anaconda,每当我在终端iTerm中打开一个新的选项卡时,我都会得到以下消息:
[WARNING]: Console output during zsh initialization detected.
When using Powerlevel10k with instant prompt, console output during zsh
initialization may indicate issues.
You can:
- Recommended: Change ~/.zshrc so that it does not perform console I/O
after the instant prompt preamble. See the link below for details.
* You will not see this error message again.
* Zsh will start quickly and prompt will update smoothly.
- Suppress this warning either by running p10k configure or by manually
defining the following parameter:
typeset -g POWERLEVEL9K_INSTANT_PROMPT=quiet
* You will not see this error message again.
* Zsh will start quickly but prompt will jump down after initialization.
- Disable instant prompt either by running p10k configure or by manually
defining the following parameter:
typeset -g POWERLEVEL9K_INSTANT_PROMPT=off
* You will not see this error message again.
* Zsh will start slowly.
- Do nothing.
* You will see this error message every time you start zsh.
* Zsh will start quickly but prompt will jump down after initialization.
For details, see:
https://github.com/romkatv/powerlevel10k/blob/master/README.md#instant-prompt
-- console output produced during zsh initialization follows --
(eval):13: unmatched "
我试过:
conda config --set changeps1 false
但没起作用。
我该怎么解决呢?
自主解决了
正如这个红边线中所述,我尝试过:
打开.zsh配置:
❯ nvim ~/.zshrc
在文件的顶部,添加以下行:
export CONDA_AUTO_ACTIVATE_BASE=false
然后重新加载zsh配置:
source ~/.zshrc
它似乎起作用了
发布于 2022-11-21 15:44:16
我也有同样的警告,因为在我的文件“~/..zshrc”中
在最后一行我有:
# Load Angular CLI autocompletion.
source <(ng completion script)
当我移除警告后,希望它能对你有所帮助。
https://stackoverflow.com/questions/73347462
复制相似问题