Skip to content

Commit 9c5b31b

Browse files
committed
Update CI
1 parent 56833a1 commit 9c5b31b

File tree

2 files changed

+46
-0
lines changed

2 files changed

+46
-0
lines changed

.github/workflows/release.yml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# This workflow will build a Java project with Gradle
2+
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
3+
4+
name: Snapshot Release
5+
6+
on:
7+
push:
8+
tags:
9+
- v[0-9]+.[0-9]+.[0-9]+-SNAPSHOT
10+
- v[0-9]+.[0-9]+.[0-9]+-[0-9a-zA-Z]+-SNAPSHOT
11+
- v[0-9]+.[0-9]+.[0-9]+-[0-9a-zA-Z]+-[0-9a-zA-Z]+-SNAPSHOT
12+
13+
jobs:
14+
release:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- name: Cancel previous workflow runs
18+
uses: styfle/cancel-workflow-action@0.9.1
19+
with:
20+
access_token: ${{ github.token }}
21+
22+
- uses: actions/checkout@v2
23+
with:
24+
submodules: recursive
25+
26+
- name: Set up JDK 11
27+
uses: actions/setup-java@v1
28+
with:
29+
java-version: 11
30+
31+
- name: Decode & Generate Settings.xml file
32+
run: echo $SETTINGS_FILE | base64 -di > ~/.m2/settings.xml
33+
env:
34+
SETTINGS_FILE: ${{ secrets.SETTINGS_XML }}
35+
36+
- name: Generate & upload library snapshot artifact JAR (Java Archive) file
37+
run: mvn clean deploy -Dmaven.test.skip=true --no-transfer-progress
38+
39+
- name: Github Release
40+
uses: softprops/action-gh-release@v1
41+
with:
42+
prerelease: ${{ contains(github.ref, '-alpha') || contains(github.ref, '-beta') }}

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,3 +27,7 @@ Integration with external systems - OpenMRS (REST and Atomfeed), DHIS2, RapidPro
2727
* [Postgres Database Support](https://smartregister.atlassian.net/wiki/spaces/Documentation/pages/251068417/Postgres+Database+Support+as+Main+Datastore)
2828

2929
* [OpenSRP Load Testing](https://smartregister.atlassian.net/wiki/spaces/Documentation/pages/268075009/OpenSRP+Load+Testing)
30+
31+
## Publishing artifacts
32+
33+
For more on publishing this artifact see [Publishing via Tag](https://smartregister.atlassian.net/wiki/spaces/Documentation/pages/3013902337/How+to+set+up+Server+Library+artifact+CI+CD+on+Github#Publishing-via-TAG)

0 commit comments

Comments
 (0)