-
Notifications
You must be signed in to change notification settings - Fork 9
148 lines (131 loc) · 5.21 KB
/
build.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
# This workflow will build a Java project with Gradle and cache/restore any dependencies to improve the workflow execution time
# For more information see: https://help.github.com/actions/language-and-framework-guides/building-and-testing-java-with-gradle
name: Build
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: set up JDK 11
uses: actions/setup-java@v2
with:
java-version: '11'
distribution: 'temurin'
cache: gradle
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Run Static Analysis
run: ./gradlew :clickstream:testReleaseUnitTest
:clickstream-api:testReleaseUnitTest
:clickstream-logger:testReleaseUnitTest
:clickstream-lifecycle:testReleaseUnitTest
:clickstream-util:testReleaseUnitTest
:clickstream-health-metrics:testReleaseUnitTest
:clickstream-health-metrics-noop:testReleaseUnitTest
:clickstream-health-metrics-api:testReleaseUnitTest
:clickstream-event-visualiser:testReleaseUnitTest
:clickstream-event-visualiser-noop:testReleaseUnitTest
:clickstream-event-visualiser-ui:testReleaseUnitTest
:clickstream-event-visualiser-ui-noop:testReleaseUnitTest
:app:testReleaseUnitTest
build:
runs-on: ubuntu-latest
needs: test
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v2
with:
java-version: '11'
distribution: 'temurin'
- name: Grant execute permission for gradlew
run: chmod +x gradlew
- name: Build with Gradle
run: ./gradlew :clickstream:assembleRelease
:clickstream-api:assembleRelease
:clickstream-logger:assembleRelease
:clickstream-lifecycle:assembleRelease
:clickstream-util:assembleRelease
:clickstream-health-metrics:assembleRelease
:clickstream-health-metrics-noop:assembleRelease
:clickstream-health-metrics-api:assembleRelease
:clickstream-event-listener:assemble
:clickstream-event-visualiser:assembleRelease
:clickstream-event-visualiser-noop:assembleRelease
:clickstream-event-visualiser-ui:assembleRelease
:clickstream-event-visualiser-ui-noop:assembleRelease
:app:assembleRelease
- name: Archive clickstream aar
uses: actions/upload-artifact@v2
with:
name: clickstream
path: clickstream/build/outputs/aar/**.aar
- name: Archive clickstream-api aar
uses: actions/upload-artifact@v2
with:
name: clickstream-api
path: clickstream-api/build/outputs/aar/**.aar
- name: Archive clickstream-logger aar
uses: actions/upload-artifact@v2
with:
name: clickstream-logger
path: clickstream-logger/build/outputs/aar/**.aar
- name: Archive clickstream-lifecycle aar
uses: actions/upload-artifact@v2
with:
name: clickstream-lifecycle
path: clickstream-lifecycle/build/outputs/aar/**.aar
- name: Archive clickstream-util aar
uses: actions/upload-artifact@v2
with:
name: clickstream-util
path: clickstream-util/build/outputs/aar/**.aar
- name: Archive clickstream-health-metrics aar
uses: actions/upload-artifact@v2
with:
name: clickstream-health-metrics
path: clickstream-health-metrics/build/outputs/aar/**.aar
- name: Archive clickstream-health-metrics-noop aar
uses: actions/upload-artifact@v2
with:
name: clickstream-health-metrics-noop
path: clickstream-health-metrics-noop/build/outputs/aar/**.aar
- name: Archive clickstream-health-metrics-api aar
uses: actions/upload-artifact@v2
with:
name: clickstream-health-metrics-api
path: clickstream-health-metrics-api/build/outputs/aar/**.aar
- name: Archive clickstream-event-listener jar
uses: actions/upload-artifact@v2
with:
name: clickstream-event-listener
path: clickstream-event-listener/build/libs/**.jar
- name: Archive clickstream-event-visualiser aar
uses: actions/upload-artifact@v2
with:
name: clickstream-event-visualiser
path: clickstream-event-visualiser/build/outputs/aar/**.aar
- name: Archive clickstream-event-visualiser-noop aar
uses: actions/upload-artifact@v2
with:
name: clickstream-event-visualiser-noop
path: clickstream-event-visualiser-noop/build/outputs/aar/**.aar
- name: Archive clickstream-event-visualiser-ui aar
uses: actions/upload-artifact@v2
with:
name: clickstream-event-visualiser-ui
path: clickstream-event-visualiser-ui/build/outputs/aar/**.aar
- name: Archive clickstream-event-visualiser-ui-noop aar
uses: actions/upload-artifact@v2
with:
name: clickstream-event-visualiser-ui-noop
path: clickstream-event-visualiser-ui-noop/build/outputs/aar/**.aar