forked from odpi/egeria
-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (48 loc) · 1.88 KB
/
merge-gradle.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
# SPDX-License-Identifier: Apache-2.0
# Copyright Contributors to the ODPi Egeria project.
name: "Publish JavaDoc"
# Trigger after code is merged. only on main repo
# - does not run on modification (may be just text)
on:
push:
branches: [main]
permissions:
contents: read
jobs:
build:
permissions:
contents: write # for JamesIves/github-pages-deploy-action to push changes in repo
runs-on: ubuntu-latest
name: "Javadoc"
if: startsWith(github.repository,'odpi/')
steps:
- uses: actions/checkout@v3
name: Checkout source
if: ${{ github.repository == 'odpi/egeria' && github.ref == 'refs/heads/main'}}
- uses: gradle/wrapper-validation-action@v1
if: ${{ github.repository == 'odpi/egeria' && github.ref == 'refs/heads/main'}}
- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
# Build first - lombok & other pre-processing may be needed. safer...
- name: build
if: ${{ github.repository == 'odpi/egeria' && github.ref == 'refs/heads/main'}}
run: './gradlew -x test -x javadoc'
- name: javadoc
if: ${{ github.repository == 'odpi/egeria' && github.ref == 'refs/heads/main'}}
run: './gradlew aggregateJavadoc'
- name: publish
if: ${{ github.repository == 'odpi/egeria' && github.ref == 'refs/heads/main'}}
uses: JamesIves/github-pages-deploy-action@v4.4.1
with:
branch: gh-pages
folder: build/docs/javadoc
- name: Upload Log of any dependency failures
if: ${{ github.repository == 'odpi/egeria' && github.ref == 'refs/heads/main'}}
uses: actions/upload-artifact@v3
with:
name: Dependency Analysis Report (on failure)
path: build/reports/dependency-analysis/build-health-report.txt
if-no-files-found: ignore