# git技巧

## 一、git pull当前目录所有项目

在`~/.zshrc`或者`~/.bashrc`中加上以下内容:

```bash
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`项目。
