git技巧
一、git pull当前目录所有项目
在~/.zshrc
或者~/.bashrc
中加上以下内容:
alias git-pull-all="find . -maxdepth 3 -name .git -type d | rev | cut -c 6- | rev | xargs -I {} git -C {} pull"
然后执行source ~/.zshrc
即可使用git-pull-all
更新当前目录所有git
项目。
Last updated
Was this helpful?