forked from pintu-gupta/simple-java-maven-app
-
Notifications
You must be signed in to change notification settings - Fork 1
33 lines (28 loc) · 834 Bytes
/
Copy pathAPI.yml
File metadata and controls
33 lines (28 loc) · 834 Bytes
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
name: ASP.NET CI
on:
push:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Build with Maven
run: mvn -B package --file pom.xml
- name: Create GitHub Release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{secrets.TOKEN}}
with:
tag_name: v${{github.run_number}}
release_name: Release V${{github.run_number}}
- name: Update version
run: mvn -B versions:set -DnewVersion=v${{github.run_number}} -DgenerateBackupPoms=false
- name: Publish to GitHub Packages Apache Maven
run: mvn -B deploy -DskipTests --file pom.xml
env:
GITHUB_TOKEN: ${{ github.token }}