Skip to content

Commit

Permalink
feat: add Github Actions environment variable to isPullRequest method (
Browse files Browse the repository at this point in the history
  • Loading branch information
kuidaoring committed Sep 23, 2022
1 parent d71a579 commit 4583273
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/chilled-items-fail.md
@@ -0,0 +1,5 @@
---
"builder-util": patch
---

feat: add Github Actions environment variable to isPullRequest method to detect if build is a PR
6 changes: 5 additions & 1 deletion packages/builder-util/src/util.ts
Expand Up @@ -327,7 +327,11 @@ export function isPullRequest() {
}

return (
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)
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) ||
isSet(process.env.GITHUB_BASE_REF)
)
}

Expand Down

0 comments on commit 4583273

Please sign in to comment.