-
Notifications
You must be signed in to change notification settings - Fork 3
Mac_Terminal
bootstraponline edited this page Sep 27, 2016
·
38 revisions
-
Install iTerm2 stable
-
Install solarized dark iTerm colors.
wget https://raw.github.com/altercation/solarized/master/iterm2-colors-solarized/Solarized%20Dark.itermcolors-
iTerm2→Preferences...→Profiles→Colors→Color Presets...→Import - After importing, manually select
Solarized Darkfrom the drop down list.
-
Install Oh My ZSH
sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
-
Edit
~/.zshrcand update:ZSH_THEME="agnoster"DEFAULT_USER="your_username"plugins=(git)
-
Install powerline font
git clone https://github.com/powerline/fonts.gitcd fonts; ./install.sh-
iTerm2→Preferences...→Profiles→Text→Change Font→Meslo LG M DZ Regular for Powerline- Make sure to uncheck
Use a different font for non-ASCII text. If this is checked, the Git symbols won't render correctly.
- Make sure to uncheck
--
Open the Command Palette in visual studio code then type shell command and click Shell Command: Install 'code' command in PATH
$ code ~/.oh-my-zsh/custom/custom.zsh
alias c="$HOME/code"
alias o="code --disable-extensions --reuse-window"
alias zshconfig="o \"$HOME/.zshrc\""
alias zshcustom="o \"$HOME/.oh-my-zsh/custom/custom.zsh\""
alias zshreload=". ~/.zshrc"
alias dd="rm -rf \"$HOME/Library/Developer/Xcode/DerivedData\""
alias ddo="open \"$HOME/Library/Developer/Xcode/DerivedData\""
mc() {
mkdir "$@"
cd "$@"
}
--
ZSH shortcuts:
- Ctrl + U = Clear
- Ctrl + A = Go to start
- Ctrl + E = Go to end
- ⌥← = Back one word (option + left arrow)
- ⌥→ = Forward one word (option + right arrow)
Configure left ⌥ to act as +Esc then add Escape codes for ⌥← and ⌥→
--
Set working directory.
Preferences → Profile → General → Working directory.... → Advanced Configuration
-
Working Directory for New Windows→~/code -
Working Directory for New Tabs→ Reuse previous session's directory
--
General usage tip:
- Store code in
~/code.Make Aliason desktop so it's easy to reach via Finder.
--
Jump directly to a location in a path
Option + Click
--
History info
cat ~/.zsh_historyhistory