-
Notifications
You must be signed in to change notification settings - Fork 0
43 lines (34 loc) · 1.15 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
# Workflow executed on "release" events.
name: release
on:
release:
types: [published]
jobs:
# Deploy to Github Packages.
deploy:
name: Deploy to Github Packages
runs-on: ubuntu-latest
container:
image: maven:3.6-alpine
steps:
# Retrieve the code from Github.
- uses: actions/checkout@v2
# Compile
- name: Compile the WAR archive.
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: mvn -B -e --settings settings.xml package
# Upload
- name: Upload Release Asset
id: upload-release-asset
# https://github.com/actions/upload-release-asset
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
upload_url: ${{ github.event.release.upload_url }}
# NOTE: actions/upload-release-asset@v1 do not support metacharacters in asset_path
# https://github.com/actions/upload-release-asset/issues/47
asset_path: target/atlasmapper.zip
asset_name: atlasmapper_${{ github.event.release.tag_name }}.zip
asset_content_type: application/zip