iTerm2 設置的彎路
1. 下載iTerm2
2. iTerm2 的配色方案
- iterm2 - preferences - profiles - color Preset進行配色預設,可以到網上下載喜歡的配色方案
- key的設置:快捷鍵 option + space
- 寬度設置
- 背景透明度與模糊度:profiles - window中設置
3. bash更改配色方案
- 修改 ~/.bash_profile 插入以下內容,注意export后面是空格,完成后 source .bash_profile
export CLICOLOR=1
LSCOLORS=gxfxcxdxbxegedabagacad
export PS1='\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;36m\]\w\[\033[00m\]\$'
export TERM=xterm-color
- 設置終端 xterm-256color
- ls顯示彩色,注意mac下ls 與Linux下ls是不同的
alias ls ='ls-G' # OS X
alias ls = 'ls --color= atuo' # Linux
4. on the zsh 方案
- 切換到 zsh, 注意 mac os 系統已經有zsh了
chsh -s /bin/zsh # 切換默認shell
5. 奇怪的問題
- 設置結束后,每次重啟iterm2,都會彈出“can't load xxxx”的錯誤
- 排查的問題:Preferences - General - 最下面有一個Preferences ,之前打勾了 “load Preferences from a custom folder or URL”,去掉之后就OK
6. iterm2的使用
最后編輯于 :
?著作權歸作者所有,轉載或內容合作請聯系作者
平臺聲明:文章內容(如有圖片或視頻亦包括在內)由作者上傳并發布,文章內容僅代表作者本人觀點,簡書系信息發布平臺,僅提供信息存儲服務。