Skip to content

Commit 1773470

Browse files
committed
Use GITHUB_BASE_REF instead
1 parent 0dc06c8 commit 1773470

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

Makefile

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ TRAVIS := $(shell echo "$${TRAVIS:-false}")
33
PR := $(shell echo "$${TRAVIS_PULL_REQUEST:-false}")
44
BRANCH := $(shell echo "$${TRAVIS_BRANCH:-master}")
55
GITHUB_ACTIONS := $(shell echo "$${GITHUB_ACTIONS:-false}")
6-
GITHUB_HEAD_REF := $(shell echo "$${GITHUB_HEAD_REF:-false}")
6+
GITHUB_BASE_REF := $(shell echo "$${GITHUB_BASE_REF:-false}")
77
DB := example
88
IPYTHON := no
99
LOCALES := $(shell .state/env/bin/python -c "from warehouse.i18n import KNOWN_LOCALES; print(' '.join(set(KNOWN_LOCALES)-{'en'}))")
@@ -142,14 +142,20 @@ deps: .state/env/pyvenv.cfg
142142
$(BINDIR)/pip check
143143

144144
github-actions-deps:
145-
ifneq ($(GITHUB_HEAD_REF), false)
146-
git fetch origin $(GITHUB_HEAD_REF):refs/remotes/origin/$(GITHUB_HEAD_REF)
147-
git diff --name-only $(GITHUB_HEAD_REF) | grep '^requirements/' || exit 0 && $(MAKE) deps
145+
ifneq ($(GITHUB_BASE_REF), false)
146+
git fetch origin $(GITHUB_BASE_REF):refs/remotes/origin/$(GITHUB_BASE_REF)
147+
git show-ref
148+
git show-ref $(GITHUB_BASE_REF)
149+
git branch
150+
git diff --name-only $(GITHUB_BASE_REF) | grep '^requirements/' || exit 0 && $(MAKE) deps
148151
endif
149152

150153
travis-deps:
151154
ifneq ($(PR), false)
152155
git fetch origin $(BRANCH):refs/remotes/origin/$(BRANCH)
156+
git show-ref
157+
git show-ref $(BRANCH)
158+
git branch
153159
git diff --name-only $(BRANCH) | grep '^requirements/' || exit 0 && $(MAKE) deps
154160
endif
155161

0 commit comments

Comments
 (0)