@@ -15,23 +15,30 @@ jobs:
15
15
runs-on : ubuntu-18.04
16
16
17
17
steps :
18
- - uses : actions/checkout@v2
19
- - name : Set up JDK 11
20
- uses : actions/setup-java@v2
21
- with :
22
- java-version : ' 11'
23
- distribution : ' adopt'
24
- - name : Build with Maven
25
- run : ./mvnw -B package site:site --file pom.xml
26
- env :
27
- GITHUB_USERNAME : jruaux
28
- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
29
- - name : Upload coverage to Codecov
30
- uses : codecov/codecov-action@v1
31
- with :
32
- token : ${{ secrets.CODECOV_TOKEN }}
33
- - name : Deploy
34
- uses : peaceiris/actions-gh-pages@v3
35
- with :
36
- github_token : ${{ secrets.GITHUB_TOKEN }}
37
- publish_dir : ./target/site
18
+ - uses : actions/checkout@v2
19
+ - name : Set up JDK 11
20
+ uses : actions/setup-java@v2
21
+ with :
22
+ java-version : ' 11'
23
+ distribution : ' adopt'
24
+ - name : Cache local Maven repository
25
+ uses : actions/cache@v2
26
+ with :
27
+ path : ~/.m2/repository
28
+ key : ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
29
+ restore-keys : |
30
+ ${{ runner.os }}-maven-
31
+ - name : Build with Maven
32
+ run : ./mvnw -B package site:site --file pom.xml
33
+ env :
34
+ GITHUB_USERNAME : jruaux
35
+ GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
36
+ - name : Upload coverage to Codecov
37
+ uses : codecov/codecov-action@v1
38
+ with :
39
+ token : ${{ secrets.CODECOV_TOKEN }}
40
+ - name : Deploy
41
+ uses : peaceiris/actions-gh-pages@v3
42
+ with :
43
+ github_token : ${{ secrets.GITHUB_TOKEN }}
44
+ publish_dir : ./target/site
0 commit comments