Skip to content

Commit d27f4b8

Browse files
authored
Revert "Replace GH pages for javadoc.io" (#202)
Revert #201 for the meantime. javadoc.io links aren't properly checked by `test-readme-links` because it never responds with 404 (redirects to an error page and responds 200 instead). - "Artifact com.gabrielfeo:develocity-api-kotlin does not exist." (before publish or invalid version) - "Javadoc is being downloaded" (right after publish)
1 parent 19facab commit d27f4b8

File tree

4 files changed

+90
-19
lines changed

4 files changed

+90
-19
lines changed

.github/workflows/pr.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,11 @@ jobs:
7575
body-file: 'comment.md'
7676
edit-mode: replace
7777

78+
dry-run-publish-javadoc:
79+
uses: ./.github/workflows/publish-javadoc.yml
80+
with:
81+
dry_run: true
82+
7883
dry-run-publish-library:
7984
uses: ./.github/workflows/publish-library.yml
8085
with:

.github/workflows/publish-javadoc.yml

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
name: 'Publish javadoc'
2+
3+
on:
4+
push:
5+
tags: ['*']
6+
workflow_dispatch:
7+
inputs:
8+
dry_run:
9+
description: 'Dry run'
10+
type: boolean
11+
default: false
12+
workflow_call:
13+
inputs:
14+
dry_run:
15+
description: 'Dry run'
16+
type: boolean
17+
default: false
18+
19+
defaults:
20+
run:
21+
shell: bash
22+
23+
jobs:
24+
25+
build-javadoc:
26+
runs-on: ubuntu-latest
27+
steps:
28+
- name: Checkout
29+
uses: actions/checkout@v4
30+
- name: Build javadoc
31+
uses: ./.github/actions/build
32+
with:
33+
args: >-
34+
dokkaHtml
35+
'-Pversion=${{ github.ref_name }}'
36+
artifact-name: 'docs'
37+
path-to-upload: "library/build/dokka/html/**/*"
38+
39+
publish-javadoc:
40+
needs: [build-javadoc]
41+
runs-on: ubuntu-latest
42+
permissions:
43+
contents: write
44+
steps:
45+
- name: Checkout
46+
uses: actions/checkout@v4
47+
with:
48+
ref: gh-pages
49+
- name: Delete current javadoc
50+
run: rm -rf docs
51+
- name: Download new javadoc
52+
uses: actions/download-artifact@v4
53+
with:
54+
path: ./
55+
- name: Commit
56+
run: |
57+
git config user.name github-actions
58+
git config user.email github-actions@github.com
59+
git add docs
60+
git commit --allow-empty -m "Add ${{ github.ref_name }} javadoc"
61+
- name: Push
62+
run: |
63+
if [[ "${{ inputs.dry_run }}" == 'true' ]]; then
64+
args=' --dry-run'
65+
fi
66+
git push $args

README.md

Lines changed: 17 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -194,23 +194,23 @@ import com.gabrielfeo.develocity.api.model.extension.*
194194
[4]: https://github.com/square/retrofit/issues/3144#issuecomment-508300518
195195
[5]: https://docs.gradle.com/enterprise/api-manual/ref/2022.4.html
196196
[6]: https://github.com/OpenAPITools/openapi-generator/blob/master/modules/openapi-generator-gradle-plugin/README.adoc
197-
[7]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/
198-
[8]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-config/index.html
199-
[9]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-develocity-api/
200-
[11]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-develocity-api/shutdown.html
201-
[12]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-config/-cache-config/cache-enabled.html
202-
[13]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-config/-cache-config/index.html
203-
[14]: https://central.sonatype.com/artifact/com.gabrielfeo/develocity-api-kotlin/2024.1.0
204-
[16]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-config/api-url.html
205-
[17]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-config/api-token.html
206-
[18]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-builds-api/index.html
207-
[19]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api.model/-gradle-attributes/index.html
208-
[20]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-builds-api/index.html
209-
[21]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-builds-api/get-builds.html
210-
[22]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-builds-api/get-gradle-attributes.html
211-
[23]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api/-develocity-api/-default-instance/index.html
212-
[24]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api.extension/get-builds-flow.html
213-
[25]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api.extension/index.html
197+
[7]: https://gabrielfeo.github.io/develocity-api-kotlin/
198+
[8]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-config/index.html
199+
[9]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-develocity-api/
200+
[11]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-develocity-api/shutdown.html
201+
[12]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-config/-cache-config/cache-enabled.html
202+
[13]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-config/-cache-config/index.html
203+
[14]: https://central.sonatype.com/artifact/com.gabrielfeo/develocity-api-kotlin/2023.4.0
204+
[16]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-config/api-url.html
205+
[17]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-config/api-token.html
206+
[18]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-builds-api/index.html
207+
[19]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api.model/-gradle-attributes/index.html
208+
[20]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-builds-api/index.html
209+
[21]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-builds-api/get-builds.html
210+
[22]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-builds-api/get-gradle-attributes.html
211+
[23]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api/-develocity-api/-default-instance/index.html
212+
[24]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api.extension/get-builds-flow.html
213+
[25]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api.extension/index.html
214214
[26]: https://kotlinlang.org/api/kotlinx.coroutines/kotlinx-coroutines-core/kotlinx.coroutines.flow/-flow/
215215
[27]: ./examples/example-scripts/example-script.main.kts
216216
[28]: ./examples/example-project

examples/example-notebooks/MostFrequentBuilds.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -81,9 +81,9 @@
8181
"response using the `models` parameter. \"Models\" are build details that would come from other endpoints. For example, \n",
8282
"requesting models=[gradleAttributes][3] brings data from `/api/builds/{id}/gradle-attributes` in the same response.\n",
8383
"\n",
84-
"[1]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api.extension/get-builds-flow.html\n",
84+
"[1]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api.extension/get-builds-flow.html\n",
8585
"[2]: https://docs.gradle.com/enterprise/api-manual/#advanced_search_syntax \n",
86-
"[3]: https://javadoc.io/doc/com.gabrielfeo/develocity-api-kotlin/2024.1.0/library/com.gabrielfeo.develocity.api\n",
86+
"[3]: https://gabrielfeo.github.io/develocity-api-kotlin/library/com.gabrielfeo.develocity.api\n",
8787
".model/-build-model-name/gradle-attributes/index.html"
8888
]
8989
},

0 commit comments

Comments
 (0)