@zhangzhen
2017-03-25T11:30:03.000000Z
字数 1079
阅读 1264
tool
#!/bin/sh
# homebrew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
# zsh
brew install zsh;
brew install zsh-completions;
chsh -s /bin/zsh;
# on-my-zsh
sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"
# show hidden files
defaults write com.apple.finder AppleShowAllFiles YES
# soft link config files
for f in ./.*; do echo $f; done
for f in ./.*; do ln -sf .config/dotfiles/$f ~/$f; done
# git alias
git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit"
git config --global alias.lgs "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --stat"
git config alias.mylg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --author=zhangzhen"
git config alias.mylgs "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --author=zhangzhen --sata"