Skip to content

Commit 491945b

Browse files
committed
renamed workflows build.yml
1 parent 6f89320 commit 491945b

File tree

1 file changed

+36
-0
lines changed

1 file changed

+36
-0
lines changed

.github/workflows/build.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Build
2+
on:
3+
push:
4+
branches:
5+
- master # or the name of your main branch
6+
7+
jobs:
8+
build:
9+
name: Build
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v2
13+
with:
14+
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
15+
- name: Set up JDK 11
16+
uses: actions/setup-java@v1
17+
with:
18+
java-version: 11
19+
- name: Cache SonarQube packages
20+
uses: actions/cache@v1
21+
with:
22+
path: ~/.sonar/cache
23+
key: ${{ runner.os }}-sonar
24+
restore-keys: ${{ runner.os }}-sonar
25+
- name: Cache Maven packages
26+
uses: actions/cache@v1
27+
with:
28+
path: ~/.m2
29+
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
30+
restore-keys: ${{ runner.os }}-m2
31+
- name: Build and analyze
32+
env:
33+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any
34+
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
35+
SONAR_HOST_URL: ${{ secrets.SONAR_HOST_URL }}
36+
run: mvn -B verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar -Dsonar.projectKey=logicaldoc-community

0 commit comments

Comments
 (0)