From 01b6b434a0c9f678f54b8d1e97f183177a255443 Mon Sep 17 00:00:00 2001 From: Gaetan Semet Date: Mon, 18 Nov 2013 09:58:43 +0100 Subject: [PATCH] automatic git push --- custom/plugins/buildbot_dev/buildbot_dev.plugin.zsh | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/custom/plugins/buildbot_dev/buildbot_dev.plugin.zsh b/custom/plugins/buildbot_dev/buildbot_dev.plugin.zsh index b3ac4b9b6..02f459ad6 100644 --- a/custom/plugins/buildbot_dev/buildbot_dev.plugin.zsh +++ b/custom/plugins/buildbot_dev/buildbot_dev.plugin.zsh @@ -73,16 +73,14 @@ function bb_merge_prod_staging() function bb_push_with_care() { - project=$1 - shift - branch=$1 - shift + branch=$(git branches | grep "remotes/m/" | cut -d'/' -f5 | cut -d' ' -f1) + project=$(git remote -v | grep umg | tail -n 1 | cut -d'/' -f6 | cut -d' ' -f1) if [[ -z $project || -z $branch ]]; then - echo "Missing arg : " + echo "Unable to findout branches or project name :(" return fi - echo "Pushing branch $branch on project $project" + echo "Pushing branch '$branch' on project '$project'" echo "Press Enter to continue" read git push ssh://android.intel.com/a/buildbot/$project HEAD:platform/buildbot/$branch