From d9ede0ea0d2e5f57dd7c2b27afaa6b4556c1be2c Mon Sep 17 00:00:00 2001 From: decentral1se Date: Thu, 3 Jun 2021 21:59:03 +0200 Subject: [PATCH] Handle the branch dance --- plugin.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugin.sh b/plugin.sh index f39e032..a2d50c1 100755 --- a/plugin.sh +++ b/plugin.sh @@ -36,6 +36,9 @@ run_abra_cmd() { cd "/root/.abra/apps/$recipe" && \ git remote rm origin && \ git remote add origin "ssh://git@git.autonomic.zone:2222/coop-cloud/$recipe.git" + + git checkout main && git push --set-upstream origin main > /dev/null 2>&1 || \ + git checkout master && git push --set-upstream origin master > /dev/null 2>&1 fi # shellcheck disable=SC2086