-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added a CI step for generating documentation.
- Loading branch information
1 parent
7d69e1f
commit 8168362
Showing
2 changed files
with
30 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
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 |
---|---|---|
@@ -1,7 +1,30 @@ | ||
#!/bin/bash | ||
|
||
readonly THIS_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" | ||
# Create HTML documentation for the current code. | ||
|
||
trap exit SIGINT | ||
readonly THIS_DIR="$(cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd | xargs realpath)" | ||
|
||
pdoc3 --config show_inherited_members=True --html --force pacai | ||
function main() { | ||
if [[ $# -gt 1 ]]; then | ||
echo "USAGE: $0 [out dir]" | ||
exit 1 | ||
fi | ||
|
||
set -e | ||
trap exit SIGINT | ||
|
||
local outputDir="${THIS_DIR}/html" | ||
if [[ $# -gt 0 ]]; then | ||
outputDir=$1 | ||
fi | ||
|
||
cd "${THIS_DIR}" | ||
|
||
mkdir -p "${outputDir}" | ||
|
||
pdoc3 --config show_inherited_members=True --html --force --output-dir "${outputDir}" pacai | ||
|
||
return 0 | ||
} | ||
|
||
[[ "${BASH_SOURCE[0]}" == "${0}" ]] && main "$@" |