Skip to content

Commit

Permalink
Cache management
Browse files Browse the repository at this point in the history
Signed-off-by: Cédric Couralet <[email protected]>
  • Loading branch information
micedre committed Feb 3, 2021
1 parent 72d0bf6 commit 50650a4
Showing 1 changed file with 13 additions and 3 deletions.
16 changes: 13 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,20 @@ jobs:
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up JDK 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8
- name: Cache Maven packages
uses: actions/cache@v2
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
restore-keys: ${{ runner.os }}-m2
- name: Build project # This would actually build your project, using zip for an example artifact
run: |
mvn versions:set -DnewVersion=${{ github.ref }}
mvn package
mvn -B versions:set -DnewVersion=${{ github.ref }}
mvn -B package
- name: Create Release
id: create_release
uses: actions/create-release@v1
Expand All @@ -35,5 +45,5 @@ jobs:
with:
upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps
asset_path: target/keycloak-mail-whitelisting-${{ github.ref }}.jar
asset_name: keycloak-mail-whitelisting-${{ github.ref }}.zip
asset_name: keycloak-mail-whitelisting-${{ github.ref }}.jar
asset_content_type: application/jar

0 comments on commit 50650a4

Please sign in to comment.