]> source.dussan.org Git - poi.git/commitdiff
Cache Maven repo during GitHub Actions
authorMarius Volkhart <mariusvolkhart@apache.org>
Sat, 6 Feb 2021 15:23:11 +0000 (15:23 +0000)
committerMarius Volkhart <mariusvolkhart@apache.org>
Sat, 6 Feb 2021 15:23:11 +0000 (15:23 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1886257 13f79535-47bb-0310-9956-ffa450edef68

.github/workflows/test-maven.yml

index 5b6a47a643995f713881b46923c65bf9817e9095..9f11477a9597b49420c9496952a3147f5e70be6d 100644 (file)
@@ -25,10 +25,10 @@ jobs:
     - name: Cache
       uses: actions/cache@v2.1.3
       with:
-        # A list of files, directories, and wildcard patterns to cache and restore
-        path: lib
-        # An explicit key for restoring and saving the cache
-        key: poi-third-party-libs
+        path: ~/.m2/repository
+        key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
+        restore-keys: |
+          ${{ runner.os }}-maven-
 
     - name: Build with Maven
       run: (cd sonar && mvn -B validate package --file pom.xml)