From e24a17815849338bf92e38ad7e42b7be79ea2c96 Mon Sep 17 00:00:00 2001 From: Aishwarya-U-R <91450662+Aishwarya-U-R@users.noreply.github.com> Date: Sat, 17 Jun 2023 11:54:32 +0530 Subject: [PATCH] ci: Set Branch name (#24571) ## Description - This PR tries to set the proper branch name of a PR --- .github/workflows/ci-test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/ci-test.yml b/.github/workflows/ci-test.yml index 247191957f..a387040c1e 100644 --- a/.github/workflows/ci-test.yml +++ b/.github/workflows/ci-test.yml @@ -253,7 +253,7 @@ jobs: # using GitHub Actions environment file # https://docs.github.com/en/actions/learn-github-actions/workflow-commands-for-github-actions#environment-files run: | - echo COMMIT_INFO_BRANCH=$(git rev-parse --abbrev-ref HEAD) >> $GITHUB_ENV + echo COMMIT_INFO_BRANCH=$(git --git-dir=.git rev-parse --abbrev-ref HEAD) >> $GITHUB_ENV echo COMMIT_INFO_MESSAGE=Run from PR# ${{ inputs.pr }} on commit $(git show -s --pretty=%H | cut -c 1-7) >> $GITHUB_ENV echo COMMIT_INFO_EMAIL=$(git show -s --pretty=%ae) >> $GITHUB_ENV echo COMMIT_INFO_AUTHOR=$(git show -s --pretty=%an) >> $GITHUB_ENV