INFRA-3209 | Dhruv | test more than 2 commit difference

This commit is contained in:
dhruvjoshi
2024-05-02 11:24:36 +05:30
parent e3096d8f4e
commit d102387d47
2 changed files with 3 additions and 3 deletions

View File

@@ -28,8 +28,8 @@ jobs:
cd kutegen
git config remote.origin.fetch "+refs/heads/*:refs/remotes/origin/*"
git fetch origin main
BEHIND=$(git rev-list main ^HEAD --count)
AHEAD=$(git rev-list HEAD ^main --count)
BEHIND=$(git rev-list origin/main ^HEAD --count)
AHEAD=$(git rev-list HEAD ^origin/main --count)
if [ $AHEAD -gt 2 ]; then
echo "Submodule is more than 2 commits ahead of main branch."
exit 1