#!/usr/bin/env zsh pushd $HOME/github_repos for x in `find -maxdepth 1 -type d | grep -v '^[.]$'`; do pushd $x if [[ -d .git ]]; then git pull fi popd done popd