Skip to content

Commit 4583273

Browse files
authored
feat: add Github Actions environment variable to isPullRequest method (#7152)
1 parent d71a579 commit 4583273

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

.changeset/chilled-items-fail.md

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"builder-util": patch
3+
---
4+
5+
feat: add Github Actions environment variable to isPullRequest method to detect if build is a PR

packages/builder-util/src/util.ts

+5-1
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,11 @@ export function isPullRequest() {
327327
}
328328

329329
return (
330-
isSet(process.env.TRAVIS_PULL_REQUEST) || isSet(process.env.CIRCLE_PULL_REQUEST) || isSet(process.env.BITRISE_PULL_REQUEST) || isSet(process.env.APPVEYOR_PULL_REQUEST_NUMBER)
330+
isSet(process.env.TRAVIS_PULL_REQUEST) ||
331+
isSet(process.env.CIRCLE_PULL_REQUEST) ||
332+
isSet(process.env.BITRISE_PULL_REQUEST) ||
333+
isSet(process.env.APPVEYOR_PULL_REQUEST_NUMBER) ||
334+
isSet(process.env.GITHUB_BASE_REF)
331335
)
332336
}
333337

0 commit comments

Comments
 (0)