Skip to content

Commit 3084918

Browse files
yifeihbulldozer-bot[bot]
authored andcommitted
allow circle to build for remote branches (take 2) (apache-spark-on-k8s#496)
1 parent 1ead46b commit 3084918

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

.circleci/config.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,11 +106,13 @@ step_templates:
106106
if [ -n "$CIRCLE_TAG" ]
107107
then
108108
git fetch origin "+refs/tags/${CIRCLE_TAG}:refs/tags/${CIRCLE_TAG}"
109+
elif [ -n "$CIRCLE_PR_NUMBER" ]
110+
then
111+
git fetch origin "+${CIRCLE_BRANCH}/head:remotes/origin/${CIRCLE_BRANCH}"
109112
else
110113
git fetch origin "+${CIRCLE_BRANCH}:remotes/origin/${CIRCLE_BRANCH}"
111114
fi
112115
113-
114116
if [ -n "$CIRCLE_TAG" ]
115117
then
116118
git reset --hard "$CIRCLE_SHA1"

0 commit comments

Comments
 (0)