Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh
- githost=fsck.com
- if [ ! -d ~/git/bps ]; then
- mkdir -p ~/git/bps
- fi
- cd ~/git/bps
- for repo in $(ssh $githost 'ls /git'); {
- if [ -d $repo ]; then
- echo "Updating repo $repo"
- (cd $repo; git pull)
- else
- echo "Mirroring new repo $repo"
- git clone $githost:/git/$repo $repo;
- fi
- }
- if [ ! -d ~/git/bps-private ]; then
- mkdir -p ~/git/bps-private
- fi
- cd ~/git/bps-private
- for repo in $(ssh $githost 'ls /git-private'); {
- if [ -d $repo ]; then
- echo "Updating repo $repo"
- (cd $repo; git pull)
- else
- echo "Mirroring new repo $repo"
- git clone $githost:/git-private/$repo $repo;
- fi
- }
Add Comment
Please, Sign In to add comment