Skip to content

Commit f65b05f

Browse files
committed
Define dev->feature->main PR workflows
1 parent 0f7d6ef commit f65b05f

File tree

3 files changed

+110
-0
lines changed

3 files changed

+110
-0
lines changed
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: "PR Checks for `main` documentation"
2+
on:
3+
pull_request:
4+
types:
5+
- opened # initially opened
6+
- reopened # closed then opened again
7+
- synchronize # any changes pushed
8+
branches:
9+
- main
10+
paths: # Only run checks on changes to documentation
11+
- "**/docs/*"
12+
- "*/README.md"
13+
14+
jobs:
15+
setup:
16+
name: "Setup Environment"
17+
runs-on: [ubuntu-22.04]
18+
if: github.event.pull_request.draft == false # ignore draft pull requests
19+
# env:
20+
#
21+
# outputs:
22+
#
23+
steps:
24+
- name: "Checkout Project"
25+
uses: actions/checkout@v4
26+
- name: "Setup Java 17"
27+
uses: actions/setup-java@v4
28+
with:
29+
distribution: 'temurin' # See 'Supported distributions' for available options
30+
java-version: '17'
31+
- name: "Setup Gradle"
32+
uses: gradle/actions/setup-gradle@v3
33+
34+
- name: "Generate Documentation"
35+
run: ./gradlew dokka
36+
37+
# - run: upload documentation to GitHub pages site
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: "PR Checks for feature branches"
2+
on:
3+
pull_request:
4+
types:
5+
- opened # initially opened
6+
- reopened # closed then opened again
7+
- synchronize # any changes pushed
8+
branches:
9+
- "feature/*"
10+
paths-ignore: # Only run checks on changes to code
11+
- "**/docs/*"
12+
- "*/README.md"
13+
14+
jobs:
15+
build:
16+
name: "Setup Environment"
17+
runs-on: [ubuntu-22.04]
18+
if: github.event.pull_request.draft == false # ignore draft pull requests
19+
# env:
20+
#
21+
# outputs:
22+
#
23+
steps:
24+
- name: "Checkout Project"
25+
uses: actions/checkout@v4
26+
- name: "Setup Java 17"
27+
uses: actions/setup-java@v4
28+
with:
29+
distribution: 'temurin' # See 'Supported distributions' for available options
30+
java-version: '17'
31+
- name: "Setup Gradle"
32+
uses: gradle/actions/setup-gradle@v3
33+
34+
- name: "Build: Assemble and Test entire project"
35+
run: ./gradlew build
36+
37+
# - run: ./gradlew generate coverage report, upload test/coverage reports
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: "PR Checks for `main`"
2+
on:
3+
pull_request:
4+
types:
5+
- opened # initially opened
6+
- reopened # closed then opened again
7+
- synchronize # any changes pushed
8+
branches:
9+
- main
10+
paths-ignore: # Only run checks on changes to code
11+
- "**/docs/*"
12+
- "*/README.md"
13+
14+
jobs:
15+
setup:
16+
name: "Setup Environment"
17+
runs-on: [ubuntu-22.04]
18+
# env:
19+
#
20+
# outputs:
21+
#
22+
steps:
23+
- name: "Checkout Project"
24+
uses: actions/checkout@v4
25+
- name: "Setup Java 17"
26+
uses: actions/setup-java@v4
27+
with:
28+
distribution: 'temurin' # See 'Supported distributions' for available options
29+
java-version: '17'
30+
- name: "Setup Gradle"
31+
uses: gradle/actions/setup-gradle@v3
32+
33+
- name: "Build: Assemble and Test entire project"
34+
run: ./gradlew build
35+
36+
# - run: ./gradlew generate coverage report, upload test/coverage reports

0 commit comments

Comments
 (0)