現象
每天第一次打開mac的終端時,最會卡一會兒才會進入ohmyzsh,再次打開則很快。發現這是ohmyzsh在自動檢查更新,將自動更新檢查關閉了就OK了。
打開個人目錄下的ohmyzsh(zsh) 的配置文件: ~/.zshrc
找到DISABLE_AUTO_UPDATE一行,將行首的注釋'#'去掉,則可禁用ohmyzsh 自動檢查更新。
PS:如果想手動檢查更新,可以手動執行
➜ ~ upgrade_oh_my_zsh
Updating Oh My Zsh
remote: Enumerating objects: 9, done.
remote: Counting objects: 100% (9/9), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 5 (delta 3), reused 4 (delta 2), pack-reused 0
展開對象中: 100% (5/5), 完成.
來自 https://github.com/robbyrussell/oh-my-zsh
* branch master -> FETCH_HEAD
a2995014..fabee559 master -> origin/master
更新 a2995014..fabee559
Fast-forward
plugins/ssh-agent/ssh-agent.plugin.zsh | 23 ++++++++++++++++-------
1 file changed, 16 insertions(+), 7 deletions(-)
當前分支 master 是最新的。
__ __
____ / /_ ____ ___ __ __ ____ _____/ /_
/ __ \/ __ \ / __ `__ \/ / / / /_ / / ___/ __ \
/ /_/ / / / / / / / / / / /_/ / / /_(__ ) / / /
\____/_/ /_/ /_/ /_/ /_/\__, / /___/____/_/ /_/
/____/
Hooray! Oh My Zsh has been updated and/or is at the current version.
To keep up on the latest news and updates, follow us on twitter: https://twitter.com/ohmyzsh
Get your Oh My Zsh swag at: https://shop.planetargon.com/