diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml new file mode 100644 index 0000000..4b43a8b --- /dev/null +++ b/.github/workflows/build.yml @@ -0,0 +1,20 @@ +name: Build +on: + push: + branches: + - master + pull_request: + types: [opened, synchronize, reopened] +jobs: + sonarcloud: + name: SonarCloud + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis + - name: SonarCloud Scan + uses: SonarSource/sonarcloud-github-action@master + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any + SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} diff --git a/sonar-project.properties b/sonar-project.properties index c72b026..114b4cc 100644 --- a/sonar-project.properties +++ b/sonar-project.properties @@ -1,8 +1,9 @@ # must be unique in a given SonarQube instance -sonar.projectKey=RVDM-Angular-Starterkit -sonar.projectName=RVDM-Angular-Starterkit +sonar.projectKey=rickvandermey_angular-starterkit +sonar.projectName=rickvandermey_angular-starterkit sonar.organization=rickvandermey + sonar.pullrequest.github.repository=rickvandermey/angular-starterkit sonar.links.homepage=https://github.com/rickvandermey/angular-starterkit sonar.links.ci=https://travis-ci.org/rickvandermey/angular-starterkit