在~/.zshrc或者~/.bashrc中加上以下内容:
~/.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项目。
source ~/.zshrc
git-pull-all
git
Last updated 4 years ago
Was this helpful?