Skip to content

Commit

Permalink
.github
Browse files Browse the repository at this point in the history
  • Loading branch information
bierdosenhalter committed Aug 17, 2022
1 parent f421b67 commit f3c6069
Show file tree
Hide file tree
Showing 2 changed files with 36 additions and 24 deletions.
14 changes: 14 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,3 +13,17 @@ updates:
commit-message:
prefix: "maven"
include: "scope"

- package-ecosystem: "github-actions"
directory: "/"
schedule:
interval: "daily"
time: "12:00"
timezone: "Europe/Berlin"
assignees:
- "bierdosenhalter"
reviewers:
- "bierdosenhalter"
commit-message:
prefix: "github-actions"
include: "scope"
46 changes: 22 additions & 24 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,42 +10,40 @@ jobs:
runs-on: ubuntu-latest
steps:

- name: checkout changes
uses: actions/checkout@v2
- name: Git
uses: actions/checkout@v3

- name: get commit info
run: echo ::set-env name=SHA::"$GITHUB_SHA"
- name: Java
uses: actions/setup-java@v3.4.1
with:
distribution: 'adopt'
java-version: '8'

- name: Cache
uses: actions/cache@v3.0.7
with:
path: ~/.m2
key: '${{ runner.os }}-m2-${{ hashFiles(''**/pom.xml'') }}'
restore-keys: '${{ runner.os }}-m2'

- name: prepare release
- name: Package
run: mvn --batch-mode --show-version --errors package --file pom.xml

- name: Draft
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: ${{ github.ref }}
body: automated release at commit ${{ env.SHA }}
body: 'automated release at commit ${{ github.sha }}'
draft: false
prerelease: false

- name: prepare java 1.8
uses: actions/setup-java@v1
with:
java-version: 1.8

- name: prepare depdendency cache
uses: actions/cache@v2
with:
path: ~/.m2
key: '${{ runner.os }}-m2-${{ hashFiles(''**/pom.xml'') }}'
restore-keys: '${{ runner.os }}-m2'

- name: run maven package
run: mvn -B package --file pom.xml

- name: upload release asset
- name: Release
uses: csexton/release-asset-action@v2
with:
pattern: "target/*.jar"
pattern: "target/AntiIllegals-*.jar"
github-token: ${{ secrets.GITHUB_TOKEN }}
release-url: ${{ steps.create_release.outputs.upload_url }}
release-url: ${{ steps.create_release.outputs.upload_url }}

0 comments on commit f3c6069

Please sign in to comment.