Aliens

在Gerrit上建立Android代码仓库

April 2, 2021
1
2
3
4
5
6
7
8
GIT_USR=gerrit-admin
GERRIT_HOST=192.168.1.1
PARENT_REPO=aosp-parent-repo
GERRIT_REPO_OWNER_GRP=aosp-admin

repo forall -vc 'ssh -p 29418 $GIT_USR@$GERRIT_HOST gerrit create-project --owner $GERRIT_REPO_OWNER_GRP $REPO_PROJECT;'
repo forall -vc 'ssh -p 29418 $GIT_USR@$GERRIT_HOST gerrit set-project-parent --parent $PARENT_REPO $REPO_PROJECT;'
repo forall -c 'git push ssh://$GIT_USR@$GERRIT_HOST:29418/$REPO_PROJECT +refs/heads/* +refs/tags/*'