Fix commit message length 86/16386/1
authorAric Gardner <agardner@linuxfoundation.org>
Wed, 31 Jul 2019 19:04:08 +0000 (15:04 -0400)
committerAric Gardner <agardner@linuxfoundation.org>
Wed, 31 Jul 2019 19:07:31 +0000 (15:07 -0400)
Also provide better error message on failure
to push .gitreview to a new repository

Signed-off-by: Aric Gardner <agardner@linuxfoundation.org>
Change-Id: I758d35ba9ca6d95828d2b1a341cc44e39476d742

shell/gerrit_create

index 6500629..0c9ba16 100755 (executable)
@@ -151,6 +151,7 @@ defaultbranch=master\n" "$project" "$repository" > .gitreview
       echo "git push of .gitreview succeeded"
     else
       echo "git push of .gitreview failed"
+      echo "Admins do not have push on refs/heads"
       exit 1
     fi
   else
@@ -172,7 +173,7 @@ enable_github_replication () {
   cat project.config
 
   git add project.config
-  git commit -sv -m "Pushing $repository project.config to refs/meta/config"
+  git commit -sv -m "Pushing $repository project.config"
 
   if git push origin HEAD:refs/meta/config &> /dev/null; then
     echo "git push for $repository refs meta config succeeded"
@@ -182,6 +183,8 @@ enable_github_replication () {
   fi
 
   echo "Starting replication"
+  echo "If this hangs, you need to give the replication group in"
+  echo "github write access to the repository"
   ssh -p 29418 "$user"@"$project" "replication start --wait $repository"
 
 }