update
This commit is contained in:
34
.github/workflows/build.yml
vendored
34
.github/workflows/build.yml
vendored
@@ -1,36 +1,22 @@
|
||||
name: Build
|
||||
on:
|
||||
# Trigger analysis when pushing in master or pull requests, and when creating
|
||||
# a pull request.
|
||||
push:
|
||||
branches:
|
||||
- beanstalk-java8
|
||||
pull_request:
|
||||
types: [opened, synchronize, reopened]
|
||||
name: Main Workflow
|
||||
jobs:
|
||||
build:
|
||||
name: Build
|
||||
sonarcloud:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
with:
|
||||
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
|
||||
- name: Set up JDK 8
|
||||
uses: actions/setup-java@v1
|
||||
with:
|
||||
java-version: 8
|
||||
- name: Cache SonarCloud packages
|
||||
uses: actions/cache@v1
|
||||
with:
|
||||
path: ~/.sonar/cache
|
||||
key: ${{ runner.os }}-sonar
|
||||
restore-keys: ${{ runner.os }}-sonar
|
||||
- name: Cache Maven packages
|
||||
uses: actions/cache@v1
|
||||
with:
|
||||
path: ~/.m2
|
||||
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
|
||||
restore-keys: ${{ runner.os }}-m2
|
||||
- name: Build and analyze
|
||||
# Disabling shallow clone is recommended for improving relevancy of reporting
|
||||
fetch-depth: 0
|
||||
- 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 }}
|
||||
run: mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
|
||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
|
||||
@@ -11,12 +11,6 @@
|
||||
|
||||
<artifactId>ms-launcher</artifactId>
|
||||
|
||||
<properties>
|
||||
<sonar.projectKey>sofieneBK_hands-on-hexagonal-architecture-with-spring-boot</sonar.projectKey>
|
||||
<sonar.organization>sofienebk</sonar.organization>
|
||||
<sonar.host.url>https://sonarcloud.io</sonar.host.url>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.example</groupId>
|
||||
|
||||
6
sonar-project.properties
Normal file
6
sonar-project.properties
Normal file
@@ -0,0 +1,6 @@
|
||||
sonar.organization=sofienebk
|
||||
sonar.projectKey=sofieneBK_hands-on-hexagonal-architecture-with-spring-boot
|
||||
|
||||
# relative paths to source directories. More details and properties are described
|
||||
# in https://sonarcloud.io/documentation/project-administration/narrowing-the-focus/
|
||||
sonar.sources=.
|
||||
Reference in New Issue
Block a user