Skip to content
This repository was archived by the owner on Sep 11, 2024. It is now read-only.

Commit cda3113

Browse files
authored
Tweak sonar-project.properties (#8498)
1 parent d793490 commit cda3113

File tree

2 files changed

+6
-11
lines changed

2 files changed

+6
-11
lines changed

scripts/fetchdep.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ defbranch="$3"
1010

1111
rm -r "$defrepo" || true
1212

13+
PR_ORG=${PR_ORG:-"matrix-org"}
14+
PR_REPO=${PR_REPO:-"matrix-react-sdk"}
15+
1316
# A function that clones a branch of a repo based on the org, repo and branch
1417
clone() {
1518
org=$1
@@ -29,8 +32,7 @@ getPRInfo() {
2932
if [ -n "$number" ]; then
3033
echo "Getting info about a PR with number $number"
3134

32-
apiEndpoint="https://api.github.com/repos/${REPOSITORY:-"matrix-org/matrix-react-sdk"}/pulls/"
33-
apiEndpoint+=$number
35+
apiEndpoint="https://api.github.com/repos/$PR_ORG/$PR_REPO/pulls/$number"
3436

3537
head=$(curl $apiEndpoint | jq -r '.head.label')
3638
fi
@@ -58,7 +60,7 @@ TRY_ORG=$deforg
5860
TRY_BRANCH=${BRANCH_ARRAY[0]}
5961
if [[ "$head" == *":"* ]]; then
6062
# ... but only match that fork if it's a real fork
61-
if [ "${BRANCH_ARRAY[0]}" != "matrix-org" ]; then
63+
if [ "${BRANCH_ARRAY[0]}" != "$PR_ORG" ]; then
6264
TRY_ORG=${BRANCH_ARRAY[0]}
6365
fi
6466
TRY_BRANCH=${BRANCH_ARRAY[1]}

sonar-project.properties

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,6 @@
11
sonar.projectKey=matrix-react-sdk
22
sonar.organization=matrix-org
33

4-
# This is the name and version displayed in the SonarCloud UI.
5-
#sonar.projectName=matrix-react-sdk
6-
#sonar.projectVersion=1.0
7-
8-
# Path is relative to the sonar-project.properties file. Replace "\" by "/" on Windows.
9-
#sonar.sources=.
10-
114
# Encoding of the source code. Default is default system encoding
125
#sonar.sourceEncoding=UTF-8
136

@@ -17,5 +10,5 @@ sonar.exclusions=__mocks__,docs
1710

1811
sonar.typescript.tsconfigPath=./tsconfig.json
1912
sonar.javascript.lcov.reportPaths=coverage/lcov.info
20-
sonar.coverage.exclusions=spec/*.ts
13+
sonar.coverage.exclusions=test/**/*,cypress/**/*
2114
sonar.testExecutionReportPaths=coverage/test-report.xml

0 commit comments

Comments
 (0)