-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add scripts/javadoc.sh lint/build script
- Loading branch information
1 parent
69eec06
commit 5943313
Showing
3 changed files
with
23 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,11 +11,13 @@ jobs: | |
uses: actions/setup-java@v4 | ||
with: | ||
distribution: 'temurin' | ||
java-version: '8' | ||
java-version: '11' | ||
- name: Install Clojure tools | ||
uses: DeLaGuardo/[email protected] | ||
with: | ||
lein: 'latest' | ||
- run: lein kaocha | ||
- run: lein kondo | ||
- run: lein fmt | ||
- run: lein fmt | ||
- name: lint javadoc | ||
run: ./scripts/javadoc.sh |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
#!/bin/bash | ||
|
||
# Best practice shell options | ||
set -euo pipefail | ||
IFS=$'\n\t' | ||
|
||
# Run the javadoc command with the -quiet option | ||
OUTPUT=`javadoc -quiet -classpath "$(lein classpath)" -Xdoclint:all -d target/javadoc-out $(find src -name "*.java") 2>&1` | ||
|
||
# Check if there is any output | ||
if [ -n "$OUTPUT" ]; then | ||
echo "Javadoc warnings or errors detected:" | ||
echo "$OUTPUT" | ||
exit 1 | ||
else | ||
echo "Javadoc completed successfully with no warnings or errors." | ||
exit 0 | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters