summaryrefslogtreecommitdiff
path: root/git-shell-commands/fetch-mirrors
blob: afff064c156112c0c4fbbd36f52ed6b98c2ef560 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/bin/sh
# * fetch-mirrors
#   Update the created `mirrors` with `mirror`
#   ssh git@host fetch-mirrors

set -e

# Find all mirrors
"$(dirname "$0")"/mirrors | while read -r mirror; do
    pushd "$mirror" >/dev/null
    git remote update
    popd >/dev/null
done