Avoid cloning repositories every time.
Signed-off-by: Nicolás Ortega Froysa <nicolas@ortegas.org>
This commit is contained in:
parent
a5d1868b8c
commit
a44951bbd3
9
sync.sh
9
sync.sh
@ -15,14 +15,15 @@ do
|
|||||||
|
|
||||||
if [ -d "$NAME" ]
|
if [ -d "$NAME" ]
|
||||||
then
|
then
|
||||||
rm -r $NAME
|
cd $NAME
|
||||||
fi
|
git remote update
|
||||||
|
else
|
||||||
git clone --mirror $ORIG
|
git clone --mirror $ORIG
|
||||||
cd $NAME
|
cd $NAME
|
||||||
|
fi
|
||||||
|
|
||||||
git push --mirror $DEST
|
git push --mirror $DEST
|
||||||
cd ..
|
cd ..
|
||||||
rm -r $NAME
|
|
||||||
|
|
||||||
echo "Done."
|
echo "Done."
|
||||||
done <./repo-list
|
done <./repo-list
|
||||||
|
Loading…
Reference in New Issue
Block a user