File tree 6 files changed +159
-109
lines changed
6 files changed +159
-109
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change 2
2
3
3
# global
4
4
* @ buchi-busireddy @ tim-mwangi @ surajpuvvada @ avinashkolluru
5
+
6
+ # GH action
7
+ .github / @ aaron-steinfeld @ jbahire @ kotharironak @ buchi-busireddy
Original file line number Diff line number Diff line change
1
+ name : build and validate
2
+ on :
3
+ push :
4
+ branches :
5
+ - main
6
+ pull_request_target :
7
+ branches :
8
+ - main
9
+
10
+ jobs :
11
+ build :
12
+ runs-on : ubuntu-20.04
13
+ steps :
14
+ # Set fetch-depth: 0 to fetch commit history and tags for use in version calculation
15
+ - name : Check out code
16
+
17
+ with :
18
+ ref : ${{github.event.pull_request.head.ref}}
19
+ repository : ${{github.event.pull_request.head.repo.full_name}}
20
+ fetch-depth : 0
21
+
22
+ - name : create checksum file
23
+ uses : hypertrace/github-actions/checksum@main
24
+
25
+ - name : Cache packages
26
+ id : cache-packages
27
+ uses : actions/cache@v2
28
+ with :
29
+ path : ~/.gradle
30
+ key : gradle-packages-${{ runner.os }}-${{ github.job }}-${{ hashFiles('**/checksum.txt') }}
31
+ restore-keys : |
32
+ gradle-packages-${{ runner.os }}-${{ github.job }}
33
+ gradle-packages-${{ runner.os }}
34
+
35
+ - name : Build with Gradle
36
+ uses : hypertrace/github-actions/gradle@main
37
+ with :
38
+ args : build
39
+
40
+ snyk-scan :
41
+ runs-on : ubuntu-20.04
42
+ steps :
43
+ # Set fetch-depth: 0 to fetch commit history and tags for use in version calculation
44
+ - name : Check out code
45
+
46
+ with :
47
+ ref : ${{github.event.pull_request.head.ref}}
48
+ repository : ${{github.event.pull_request.head.repo.full_name}}
49
+ fetch-depth : 0
50
+ - name : Setup snyk
51
+ uses :
snyk/actions/[email protected]
52
+ - name : Snyk test
53
+ run : snyk test --all-sub-projects --org=hypertrace --severity-threshold=low --policy-path=.snyk --configuration-matching='^runtimeClasspath$'
54
+ env :
55
+ SNYK_TOKEN : ${{ secrets.SNYK_TOKEN }}
Original file line number Diff line number Diff line change
1
+ name : test
2
+ on :
3
+ push :
4
+ branches :
5
+ - main
6
+ pull_request :
7
+
8
+ jobs :
9
+ test :
10
+ runs-on : ubuntu-20.04
11
+ steps :
12
+ # Set fetch-depth: 0 to fetch commit history and tags for use in version calculation
13
+ - name : Check out code
14
+
15
+ with :
16
+ fetch-depth : 0
17
+
18
+ - name : create checksum file
19
+ uses : hypertrace/github-actions/checksum@main
20
+
21
+ - name : Cache packages
22
+ id : cache-packages
23
+ uses : actions/cache@v2
24
+ with :
25
+ path : ~/.gradle
26
+ key : gradle-packages-${{ runner.os }}-${{ github.job }}-${{ hashFiles('**/checksum.txt') }}
27
+ restore-keys : |
28
+ gradle-packages-${{ runner.os }}-${{ github.job }}
29
+ gradle-packages-${{ runner.os }}
30
+
31
+ - name : Unit test
32
+ uses : hypertrace/github-actions/gradle@main
33
+ with :
34
+ args : build jacocoTestReport
35
+
36
+ - name : Upload coverage to Codecov
37
+ uses : codecov/codecov-action@v1
38
+ with :
39
+ name : unit test reports
40
+ fail_ci_if_error : true
41
+ flags : unit
42
+
43
+ - name : copy test reports
44
+ uses : hypertrace/github-actions/gradle@main
45
+ with :
46
+ args : copyAllReports --output-dir=/tmp/test-reports
47
+
48
+ - name : Archive test reports
49
+ uses : actions/upload-artifact@v1
50
+ with :
51
+ name : test-reports
52
+ path : /tmp/test-reports
53
+ if : always()
54
+
55
+ - name : Publish Unit Test Results
56
+ uses : docker://ghcr.io/enricomi/publish-unit-test-result-action:v1.6
57
+ if : always()
58
+ with :
59
+ github_token : ${{ secrets.GITHUB_TOKEN }}
60
+ files : ./**/build/test-results/**/*.xml
Original file line number Diff line number Diff line change
1
+ name : Publish artifacts
2
+ on :
3
+ # Will only run when release is published.
4
+ release :
5
+ types :
6
+ - created
7
+ workflow_dispatch :
8
+
9
+ jobs :
10
+ publish-artifacts :
11
+ runs-on : ubuntu-20.04
12
+ steps :
13
+ # Set fetch-depth: 0 to fetch commit history and tags for use in version calculation
14
+ - name : Check out code
15
+
16
+ with :
17
+ fetch-depth : 0
18
+
19
+ - name : create checksum file
20
+ uses : hypertrace/github-actions/checksum@main
21
+
22
+ - name : Cache packages
23
+ uses : actions/cache@v2
24
+ with :
25
+ path : ~/.gradle
26
+ key : gradle-packages-${{ runner.os }}-${{ github.job }}-${{ hashFiles('**/checksum.txt') }}
27
+ restore-keys : |
28
+ gradle-packages-${{ runner.os }}-${{ github.job }}
29
+ gradle-packages-${{ runner.os }}
30
+
31
+ - name : publish java artifacts
32
+ uses : hypertrace/github-actions/gradle@main
33
+ with :
34
+ args : publish
35
+ env :
36
+ ORG_GRADLE_PROJECT_publishUser : ${{ secrets.BINTRAY_USER }}
37
+ ORG_GRADLE_PROJECT_publishApiKey : ${{ secrets.BINTRAY_API_KEY }}
38
+
39
+
Original file line number Diff line number Diff line change
1
+ codecov :
2
+ max_report_age : off
You can’t perform that action at this time.
0 commit comments