Skip to content

docs: JavaDoc site on maven.pinont.me - #10

Open
Pinont wants to merge 1 commit into
mainfrom
cursor/javadoc-docs-site-f59e
Open

docs: JavaDoc site on maven.pinont.me#10
Pinont wants to merge 1 commit into
mainfrom
cursor/javadoc-docs-site-f59e

Conversation

@Pinont

@Pinont Pinont commented Sep 1, 2026

Copy link
Copy Markdown
Owner

Why

Ship a public docs site with generated JavaDoc HTML, plus a small landing page that matches the Maven Central install story on main. This repo’s GitHub Pages URL (https://pinont.github.io/SingularityLib/) 301s to the pinont.me portfolio, so JavaDoc is not published there.

What

  • Landing page in docs/index.html (Central coordinates, README install link, JavaDoc entry).
  • New workflow .github/workflows/publish-javadoc.yml: on push to main and workflow_dispatch, runs mvn javadoc:javadoc and copies HTML into Pinont/singularity-maven gh-pages under /javadoc/singularitylib/ only (Maven group paths io/ / com/ untouched).
  • README links the hosted docs, plus javadoc.io as a fallback (Central sync may still be empty).
  • maven-javadoc-plugin still attaches the javadoc jar for future Central publishes (failOnError remains false).
  • pages-repo.yml is unchanged in behavior; it only shares a concurrency group so Maven-layout and JavaDoc pushes do not race, and comments that /javadoc/ must not be deleted.

Intended URLs (after merge + first publish-javadoc run)

Page URL
Landing https://maven.pinont.me/javadoc/singularitylib/
Latest JavaDoc https://maven.pinont.me/javadoc/singularitylib/latest/
Versioned (from pom) https://maven.pinont.me/javadoc/singularitylib/2.0.0-SNAPSHOT/
javadoc.io fallback https://javadoc.io/doc/io.github.pinont/singularitylib/2.0.0

Not using https://pinont.github.io/SingularityLib/ (portfolio).

Out of scope

  • No Central republish, no git tags, no GitHub release.
  • release.yml untouched.
  • Wiki left stale on purpose.

Verify

  • mvn javadoc:javadoc succeeds locally (warnings only; HTML at target/site/apidocs/index.html).
  • mvn javadoc:jar still produces singularitylib-*-javadoc.jar.
  • Both workflow YAML files parse.
Open in Web Open in Cursor 

Generate API docs with javadoc:javadoc and copy them into
Pinont/singularity-maven under /javadoc/singularitylib/ so they
sit beside the snapshot Maven repo without using this repo's
GitHub Pages (that URL is the pinont.me portfolio).

Co-authored-by: Nonnipat Tangrojjanakhajorn <contact@pinont.me>
Copilot AI lite review requested due to automatic review settings September 1, 2026 20:07

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The new publish workflow can silently succeed when version parsing or the Pages rebuild trigger fails, which can leave the hosted docs stale without failing CI.

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

Adds a public, Maven-site-hosted JavaDoc documentation site for SingularityLib by generating JavaDoc HTML in CI and publishing it into the Pinont/singularity-maven gh-pages tree under /javadoc/singularitylib/, alongside a small landing page and updated README links.

Changes:

  • Add a landing page and redirect page under docs/ for the hosted JavaDoc site.
  • Add a new GitHub Actions workflow to build JavaDoc HTML and publish it to Pinont/singularity-maven (gh-pages) under /javadoc/singularitylib/.
  • Update README and Maven Javadoc plugin configuration to align with the new docs publishing flow.
File summaries
File Description
README.md Adds a docs badge and links to the hosted JavaDoc and fallback javadoc.io.
pom.xml Centralizes maven-javadoc-plugin configuration for jar + HTML generation behavior.
docs/javadoc-root.html Adds a lightweight redirect entry point for the /javadoc/ root.
docs/index.html Adds a styled landing page with install coordinates and JavaDoc links.
.github/workflows/publish-javadoc.yml New workflow to generate and publish JavaDoc HTML to the Pages-backed Maven repo.
.github/workflows/pages-repo.yml Adds concurrency coordination/comments to avoid racing with JavaDoc publishing.
Review details
  • Files reviewed: 6/6 changed files
  • Comments generated: 2
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment on lines +39 to +40
VERSION=$(mvn -q -DforceStdout help:evaluate -Dexpression=project.version)
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
Comment on lines +108 to +111
curl -s -X POST \
-H "Authorization: Bearer ${{ secrets.MAVEN_REPO_TOKEN }}" \
-H "Accept: application/vnd.github+json" \
https://api.github.com/repos/Pinont/singularity-maven/pages/builds -o /dev/null -w "%{http_code}\n"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants