File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -291,7 +291,7 @@ jobs:
291291 echo "Current branch: $(git branch --show-current || git symbolic-ref --short HEAD 2>/dev/null || echo 'detached')"
292292 echo "Current commit: $(git rev-parse HEAD)"
293293 echo "Current commit message: $(git log -1 --pretty=format:'%s')"
294- BUILD_BRANCH="${{ github.ref_name }}"
294+ BUILD_BRANCH="${{ github.event_name == 'pull_request' && github.event.pull_request.base.ref || github. ref_name }}"
295295 echo "Building from branch: $BUILD_BRANCH"
296296 echo "Target HEAD commit: $(git rev-parse origin/$BUILD_BRANCH)"
297297 echo "Target HEAD message: $(git log -1 --pretty=format:'%s' origin/$BUILD_BRANCH)"
@@ -914,7 +914,7 @@ jobs:
914914 echo "Current branch: $(git branch --show-current || git symbolic-ref --short HEAD 2>/dev/null || echo 'detached')"
915915 echo "Current commit: $(git rev-parse HEAD)"
916916 echo "Current commit message: $(git log -1 --pretty=format:'%s')"
917- BUILD_BRANCH="${{ github.ref_name }}"
917+ BUILD_BRANCH="${{ github.event_name == 'pull_request' && github.event.pull_request.base.ref || github. ref_name }}"
918918 echo "Building from branch: $BUILD_BRANCH"
919919 echo "Target HEAD commit: $(git rev-parse origin/$BUILD_BRANCH)"
920920 echo "Target HEAD message: $(git log -1 --pretty=format:'%s' origin/$BUILD_BRANCH)"
You can’t perform that action at this time.
0 commit comments