Skip to content

Commit 0664612

Browse files
authored
chore: move javadoc to Github Action based Github Pages (#473)
1 parent aa18443 commit 0664612

2 files changed

Lines changed: 36 additions & 7 deletions

File tree

.github/workflows/build.yml

Lines changed: 35 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ on:
1919
branches:
2020
- main
2121
paths:
22+
- '.github/workflows/build.yml'
2223
- 'sdk/**'
2324
- 'sdk-testing/**'
2425
- 'sdk-integration-tests/**'
@@ -28,6 +29,7 @@ on:
2829
branches:
2930
- main
3031
paths:
32+
- '.github/workflows/build.yml'
3133
- 'sdk/**'
3234
- 'sdk-testing/**'
3335
- 'sdk-integration-tests/**'
@@ -36,6 +38,8 @@ on:
3638

3739
permissions:
3840
contents: write
41+
pages: write
42+
id-token: write
3943

4044
jobs:
4145
build:
@@ -76,12 +80,36 @@ jobs:
7680
folder: coverage-report/target/site/jacoco-aggregate
7781
target-folder: coverage
7882

79-
- name: Deploy javadoc to Github Pages
83+
- name: Generate javadoc site
8084
if: ${{ github.ref == 'refs/heads/main' && matrix.java == 17 }}
81-
uses: MathieuSoysal/Javadoc-publisher.yml@fda475b197081ba1eca7a1dfadf0c017080a1623 # v3.0.2
85+
run: mvn -B -pl sdk -am javadoc:javadoc
86+
87+
- name: Configure GitHub Pages
88+
if: ${{ github.ref == 'refs/heads/main' && matrix.java == 17 }}
89+
uses: actions/configure-pages@v5
90+
91+
- name: Prepare GitHub Pages artifact
92+
if: ${{ github.ref == 'refs/heads/main' && matrix.java == 17 }}
93+
run: |
94+
mkdir -p github-pages/coverage github-pages/javadoc
95+
cp -R coverage-report/target/site/jacoco-aggregate/. github-pages/coverage
96+
cp -R sdk/target/site/apidocs/. github-pages/javadoc
97+
touch github-pages/.nojekyll
98+
99+
- name: Upload GitHub Pages artifact
100+
if: ${{ github.ref == 'refs/heads/main' && matrix.java == 17 }}
101+
uses: actions/upload-pages-artifact@v4
82102
with:
83-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
84-
javadoc-branch: docs
85-
target-folder: javadoc
86-
java-version: 17
87-
project: maven
103+
path: github-pages
104+
105+
deploy-pages:
106+
if: ${{ github.ref == 'refs/heads/main' }}
107+
needs: build
108+
runs-on: ubuntu-latest
109+
environment:
110+
name: github-pages
111+
url: ${{ steps.deployment.outputs.page_url }}
112+
steps:
113+
- name: Deploy GitHub Pages
114+
id: deployment
115+
uses: actions/deploy-pages@v4

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ See [Deploy Lambda durable functions with Infrastructure as Code](https://docs.a
8787

8888
- [<u>AWS Documentation</u>](https://docs.aws.amazon.com/lambda/latest/dg/durable-functions.html) – Official AWS Lambda durable functions guide
8989
- [<u>Best Practices</u>](https://docs.aws.amazon.com/lambda/latest/dg/durable-best-practices.html) – Patterns and recommendations
90+
- [<u>Javadoc</u>](https://aws.github.io/aws-durable-execution-sdk-java/javadoc/) - API reference for the Java SDK
9091
- [<u>SDK Design</u>](docs/design.md) – Details of SDK internal architecture
9192

9293
**Core Operations**

0 commit comments

Comments
 (0)