Update fetchdep to also take into account forks

This commit is contained in:
Michael Telatynski 2022-04-27 22:50:28 +01:00
parent dab1488ffe
commit 0a239a30fa
5 changed files with 7 additions and 7 deletions

View file

@ -19,7 +19,8 @@ on:
SENTRY_URL:
required: true
env:
# This must be set for fetchdep.sh to get the right branch
# These must be set for fetchdep.sh to get the right branch
REPOSITORY: ${{ github.repository }}
PR_NUMBER: ${{ github.event.pull_request.number }}
jobs:
build:

View file

@ -6,9 +6,6 @@ on:
branches: [ develop ]
repository_dispatch:
types: [ element-web-notify ]
env:
# This must be set for fetchdep.sh to get the right branch
PR_NUMBER: ${{ github.event.pull_request.number }}
jobs:
build:
name: "Build"

View file

@ -6,7 +6,8 @@ on:
repository_dispatch:
types: [ element-web-notify ]
env:
# This must be set for fetchdep.sh to get the right branch
# These must be set for fetchdep.sh to get the right branch
REPOSITORY: ${{ github.repository }}
PR_NUMBER: ${{ github.event.pull_request.number }}
jobs:
ts_lint:

View file

@ -6,7 +6,8 @@ on:
repository_dispatch:
types: [ element-web-notify ]
env:
# This must be set for fetchdep.sh to get the right branch
# These must be set for fetchdep.sh to get the right branch
REPOSITORY: ${{ github.repository }}
PR_NUMBER: ${{ github.event.pull_request.number }}
jobs:
test:

View file

@ -29,7 +29,7 @@ getPRInfo() {
if [ -n "$number" ]; then
echo "Getting info about a PR with number $number"
apiEndpoint="https://api.github.com/repos/matrix-org/matrix-react-sdk/pulls/"
apiEndpoint="https://api.github.com/repos/${REPOSITORY:-"vector-im/element-web"}/pulls/"
apiEndpoint+=$number
head=$(curl $apiEndpoint | jq -r '.head.label')