# 重灌設定 前端 - 安裝 [homebrew](https://brew.sh/index_zh-tw) - 安裝 git - 安裝 vscode - 安裝 Chorme ## iterm2 相關設定 ```cmake= # 安裝 iterm2 brew cask install iterm2 # 安裝 zsh brew install zsh # 接者要把預設的 shell 改成 zsh sudo sh -c "echo $(which zsh) >> /etc/shells" chsh -s $(which zsh) # 重啟 iterm2,確認是否設定成功 應該會看到顯示 /usr/local/bin/zsh。 echo $SHELL # 安裝 Oh-my-zsh sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)" ## 如果有遇到 oh my zsh Insecure completion-dependent directories detected 的問題 sudo vim ~/.zshrc # 在第一行加入 ZSH_DISABLE_COMPFIX="true" # 保存之后,在執行: source ~/.zshrc ``` ### 設定主題 ```cmake= sudo vim ~/.zshrc # 將 ZSH_THEME="robbyrussell" 修改 ZSH_THEME="agnoster" ``` ```cmake= # 必須先執行這行,才能用 homebrew 安裝字型。執行過的人可以跳過 brew tap homebrew/cask-fonts # 安裝指令 brew cask install font-meslo-for-powerline # 其他字型也可以在 brew 上搜尋 nerd brew search nerd # Preferences -> Profiles -> Text -> Font -> Meslo xxxx ``` ### 如果想把 shell 換回 bash ```cmake= chsh -s /bin/bash ``` ## 參考 [如何讓 Terminal 看起來好用又好看|iTerms 2 + Oh-my-zsh 全攻略](https://medium.com/%E6%95%B8%E6%93%9A%E4%B8%8D%E6%AD%A2-not-only-data/macos-%E7%9A%84-terminal-%E5%A4%A7%E6%94%B9%E9%80%A0-iterms-oh-my-zsh-%E5%85%A8%E6%94%BB%E7%95%A5-77d5aae87b10)