diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml
index 548027d0..e18220d8 100644
--- a/.github/workflows/ci.yaml
+++ b/.github/workflows/ci.yaml
@@ -36,7 +36,9 @@ jobs:
path: ~/.m2/repository
key: build_maven
- name: Build
- run: ./mvnw install -e
+ run: ./mvnw install -e --ntp -B
+ - name: Javadoc
+ run: ./mvnw -P release javadoc:javadoc --ntp -B
- name: Upload generated sources
uses: actions/upload-artifact@v4
with:
@@ -80,7 +82,7 @@ jobs:
path: ~/.m2/repository
key: build_maven
- name: Test
- run: ./mvnw verify -pl it/java8 -e
+ run: ./mvnw verify -pl it/java8 -e --ntp -B
client_test:
needs: [build_and_test]
diff --git a/annotation/src/main/java/online/sharedtype/SharedType.java b/annotation/src/main/java/online/sharedtype/SharedType.java
index ff75202a..10c31d95 100644
--- a/annotation/src/main/java/online/sharedtype/SharedType.java
+++ b/annotation/src/main/java/online/sharedtype/SharedType.java
@@ -39,7 +39,6 @@
* Type hierarchy will be flattened that a subtype's inherited properties will be included in its own declared properties,
* while, by default, any supertypes will not be emitted again.
*
- *
*
*
* Inner classes:
@@ -48,11 +47,10 @@
*
*
*
- * Cyclic Reference:
+ * Cyclic Reference:
*
* - Rust: Cyclic references will be wrapped in {@code Option>}.
*
- *
*
*
* Constants:
@@ -72,9 +70,8 @@
*
Rust: {@code Vec}
*
*
- * Maps are mapped to:
*
- * Maps:
+ * Maps:
* (Not supported yet.)
*
* - Typescript: {@code [key: string]: T} where {@code T} can be a reified type.
diff --git a/doc/Development.md b/doc/Development.md
index 1ffef81f..d9ecb29e 100644
--- a/doc/Development.md
+++ b/doc/Development.md
@@ -75,3 +75,11 @@ Do not use compile time heavy annotation like `lombok.val`.
## Release
Release is via Sonatype [Central Portal](https://central.sonatype.org/register/central-portal/). Snapshot release is not supported.
Create a GitHub release, GitHub action will automatically deploy to Sonatype. Version will be automatically bumped by the action.
+
+To Test Javadoc locally:
+```bash
+./mvnw -P release javadoc:javadoc
+```
+Then open `annotation/target/reports/apidocs/index.html`.
+
+To test deployment, see [release](../misc/release.sh).
diff --git a/internal/src/main/java/online/sharedtype/processor/domain/ConcreteTypeInfo.java b/internal/src/main/java/online/sharedtype/processor/domain/ConcreteTypeInfo.java
index 88d1ffa9..bc81475d 100644
--- a/internal/src/main/java/online/sharedtype/processor/domain/ConcreteTypeInfo.java
+++ b/internal/src/main/java/online/sharedtype/processor/domain/ConcreteTypeInfo.java
@@ -38,7 +38,7 @@ public final class ConcreteTypeInfo implements TypeInfo {
/**
* The counter-parting type definition.
- * @see this#typeDef()
+ * @see #typeDef()
*/
@Nullable
private TypeDef typeDef;
diff --git a/internal/src/main/java/online/sharedtype/processor/domain/TypeInfo.java b/internal/src/main/java/online/sharedtype/processor/domain/TypeInfo.java
index 20e9539f..139686e0 100644
--- a/internal/src/main/java/online/sharedtype/processor/domain/TypeInfo.java
+++ b/internal/src/main/java/online/sharedtype/processor/domain/TypeInfo.java
@@ -14,8 +14,8 @@ public interface TypeInfo extends Serializable {
* Check if this type and its dependency types are resolved.
*
* When parsing a type's structure, a dependency type is firstly captured as a {@link TypeInfo}.
- * At this stage, because we don't know its output structure or if it needs output at all, we mark it as unresolved.
- * Also due to possible cyclic dependencies, the resolution stage needs to be performed after initial parsing state.
+ * At this stage, because we don't know its output structure or if it needs to be output at all, we mark it as unresolved.
+ * Also, due to possible cyclic dependencies, the resolution stage needs to be performed after initial parsing state.
* During resolution, once a type is parsed, it's marked as resolved.
* Note that a type is marked as resolved when created, if it can be determined at that time.
*
@@ -28,7 +28,7 @@ public interface TypeInfo extends Serializable {
/**
* Replace type variables with type arguments.
* @param mappings key is a type variable e.g. T
- * value is a type argument, a concrete type e.g. Integer, or a generic type with concrete type parameter, e.g. Tuple>
+ * value is a type argument, a concrete type e.g. Integer, or a generic type with concrete type parameter, e.g. {@code Tuple}
* @return a newly created type info if updated.
*/
TypeInfo reify(Map mappings);
diff --git a/misc/release.sh b/misc/release.sh
index 67828336..1da0cc6f 100755
--- a/misc/release.sh
+++ b/misc/release.sh
@@ -1,6 +1,11 @@
#!/bin/bash
#set -e
+# To test locally, need to prepare GPG keys
+# gpg --gen-key
+# See also: https://maven.apache.org/plugins/maven-gpg-plugin/
+# See also: https://stackoverflow.com/questions/3174537/how-to-transfer-pgp-private-key-to-another-computer
+
if [ -z "$MAVEN_GPG_PASSPHRASE" ];then
echo "No MAVEN_GPG_PASSPHRASE provided, exit 1"
exit 1
@@ -22,8 +27,8 @@ increment_version() {
snapshotVersion=$(./mvnw help:evaluate -Dexpression=project.version -q -DforceStdout)
version="$(printf '%s' "$snapshotVersion" | sed -e "s/-SNAPSHOT//g")"
-./mvnw versions:set -DgenerateBackupPoms=false -DnewVersion="$version"
-./mvnw deploy -DskipTests -Prelease # to debug release can add -DskipPublishing=true to prevent actual upload
+./mvnw versions:set -DgenerateBackupPoms=false -DnewVersion="$version" --ntp -B
+./mvnw deploy -DskipTests -Prelease --ntp -B # to debug release can add -DskipPublishing=true to prevent actual upload
NEW_VERSION="$(increment_version "$version" 1)-SNAPSHOT"
-./mvnw versions:set -DgenerateBackupPoms=false -DnewVersion="$NEW_VERSION"
+./mvnw versions:set -DgenerateBackupPoms=false -DnewVersion="$NEW_VERSION" --ntp -B
printf '%s' "$NEW_VERSION" > NEW_VERSION.cache